summaryrefslogtreecommitdiff
path: root/recipes/glibc/glibc-2.3.2/81_glibc232-utimes-fix.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/glibc/glibc-2.3.2/81_glibc232-utimes-fix.patch')
-rw-r--r--recipes/glibc/glibc-2.3.2/81_glibc232-utimes-fix.patch39
1 files changed, 39 insertions, 0 deletions
diff --git a/recipes/glibc/glibc-2.3.2/81_glibc232-utimes-fix.patch b/recipes/glibc/glibc-2.3.2/81_glibc232-utimes-fix.patch
new file mode 100644
index 0000000000..92cfa27bd5
--- /dev/null
+++ b/recipes/glibc/glibc-2.3.2/81_glibc232-utimes-fix.patch
@@ -0,0 +1,39 @@
+--- glibc-2.3.2.orig/sysdeps/posix/utimes.c 2001-07-07 20:21:27.000000000 +0100
++++ glibc-2.3.2/sysdeps/posix/utimes.c 2003-08-26 16:35:47.000000000 +0100
+@@ -31,8 +31,8 @@ __utimes (const char *file, const struct
+ if (tvp)
+ {
+ times = &buf;
+- times->actime = tvp[0].tv_sec + tvp[0].tv_usec / 1000000;
+- times->modtime = tvp[1].tv_sec + tvp[1].tv_usec / 1000000;
++ buf.actime = tvp[0].tv_sec + tvp[0].tv_usec / 1000000;
++ buf.modtime = tvp[1].tv_sec + tvp[1].tv_usec / 1000000;
+ }
+ else
+ times = NULL;
+--- glibc-2.3.2.orig/sysdeps/unix/sysv/linux/futimes.c 2003-08-26 16:34:20.000000000 +0100
++++ glibc-2.3.2/sysdeps/unix/sysv/linux/futimes.c 2003-08-26 16:35:17.000000000 +0100
+@@ -57,8 +57,8 @@ __futimes (int fd, const struct timeval
+ if (tvp != NULL)
+ {
+ times = &buf;
+- buf.actime = tvp[0].tv_sec + tvp[0].tv_usec >= 500000;
+- buf.modtime = tvp[1].tv_sec + tvp[1].tv_usec >= 500000;
++ buf.actime = tvp[0].tv_sec + tvp[0].tv_usec / 1000000;
++ buf.modtime = tvp[1].tv_sec + tvp[1].tv_usec / 1000000;
+ }
+ else
+ times = NULL;
+--- glibc-2.3.2.orig/sysdeps/unix/sysv/linux/utimes.c 2003-08-26 16:34:21.000000000 +0100
++++ glibc-2.3.2/sysdeps/unix/sysv/linux/utimes.c 2003-08-26 16:35:34.000000000 +0100
+@@ -47,8 +47,8 @@ __utimes (const char *file, const struct
+ if (tvp != NULL)
+ {
+ times = &buf;
+- buf.actime = tvp[0].tv_sec + tvp[0].tv_usec >= 500000;
+- buf.modtime = tvp[1].tv_sec + tvp[1].tv_usec >= 500000;
++ buf.actime = tvp[0].tv_sec + tvp[0].tv_usec / 1000000;
++ buf.modtime = tvp[1].tv_sec + tvp[1].tv_usec / 1000000;
+ }
+ else
+ times = NULL;