Skip to contentSkip to conversation

fix sys32_utimes(somefile, NULL)

PATCH In review Jakub Bogusz 2 participants 2 messages Jun 14, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix sys32_utimes(somefile, NULL)

This patch fixes utimes(somefile, NULL) syscalls on sparc64 kernel with 32-bit userland - use of uninitialized value resulted in making random timestamps, which confused e.g. sudo.
It has been already fixed (by davem) in linux-2.6 tree 30 months ago.

arch/sparc64/kernel/sys_sparc32.c renamed from arch/sparc64/kernel/sys_sparc32.c.orig +1 -1
@@ -4267,7 +4267,7 @@
 
 		old_fs = get_fs();
 		set_fs(KERNEL_DS);
-		ret = sys_utimes(kfilename, &ktvs[0]);
+		ret = sys_utimes(kfilename, (tvs ? &ktvs[0] : NULL));
 		set_fs(old_fs);
 
 		putname(kfilename);
Signature · 1 line
Jakub Bogusz    http://qboosh.cs.net.pl/
#1 lore raw

From: Jakub Bogusz <[email protected]>
Date: Tue, 14 Jun 2005 21:23:06 +0200

Quoted 6 lines

This patch fixes utimes(somefile, NULL) syscalls on sparc64 kernel with 32-bit userland - use of uninitialized value resulted in making random timestamps, which confused e.g. sudo.
It has been already fixed (by davem) in linux-2.6 tree 30 months ago.

Thanks a lot Jakub, I'll push this to Marcelo as soon as he opens up his 2.4.x GIT tree.