summaryrefslogtreecommitdiff
path: root/recipes/udev/udev-151/udev-replace-lutimes.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/udev/udev-151/udev-replace-lutimes.patch')
-rw-r--r--recipes/udev/udev-151/udev-replace-lutimes.patch25
1 files changed, 25 insertions, 0 deletions
diff --git a/recipes/udev/udev-151/udev-replace-lutimes.patch b/recipes/udev/udev-151/udev-replace-lutimes.patch
new file mode 100644
index 0000000000..dd77897345
--- /dev/null
+++ b/recipes/udev/udev-151/udev-replace-lutimes.patch
@@ -0,0 +1,25 @@
+This patch is needed on uclibc
+
+-Khem
+Index: udev-151/udev/udev-node.c
+===================================================================
+--- udev-151.orig/udev/udev-node.c 2010-06-04 14:18:59.082727182 -0700
++++ udev-151/udev/udev-node.c 2010-06-04 14:20:27.485282812 -0700
+@@ -57,7 +57,7 @@ int udev_node_mknod(struct udev_device *
+ preserve = 1;
+ udev_selinux_lsetfilecon(udev, file, mode);
+ /* update time stamp when we re-use the node, like on media change events */
+- utimes(file, NULL);
++ utimensat(AT_FDCWD, file, NULL, 0);
+ } else {
+ char file_tmp[UTIL_PATH_SIZE + sizeof(TMP_FILE_EXT)];
+
+@@ -178,7 +178,7 @@ static int node_symlink(struct udev *ude
+ info(udev, "preserve already existing symlink '%s' to '%s'\n",
+ slink, target);
+ udev_selinux_lsetfilecon(udev, slink, S_IFLNK);
+- lutimes(slink, NULL);
++ utimensat(AT_FDCWD, slink, NULL, AT_SYMLINK_NOFOLLOW);
+ goto exit;
+ }
+ }