aboutsummaryrefslogtreecommitdiffstats
path: root/testing/xf86-video-virtualbox/futimens.patch
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2012-09-16 14:01:41 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2012-09-16 14:20:57 +0000
commit133362eb053d4b7b9e95a2878518bb8c83e0c87a (patch)
tree170eb021c841da4f989b5018a4bac3134ef8ca64 /testing/xf86-video-virtualbox/futimens.patch
parent468668c8211152668d2246f4c165afbba9d66640 (diff)
downloadaports-133362eb053d4b7b9e95a2878518bb8c83e0c87a.tar.bz2
aports-133362eb053d4b7b9e95a2878518bb8c83e0c87a.tar.xz
testing/xf86-video-virtualbox: new aport
Xorg Virtual box video driver http://virtualbox.org ref #1349
Diffstat (limited to 'testing/xf86-video-virtualbox/futimens.patch')
-rw-r--r--testing/xf86-video-virtualbox/futimens.patch16
1 files changed, 16 insertions, 0 deletions
diff --git a/testing/xf86-video-virtualbox/futimens.patch b/testing/xf86-video-virtualbox/futimens.patch
new file mode 100644
index 0000000000..f85e1ae6e2
--- /dev/null
+++ b/testing/xf86-video-virtualbox/futimens.patch
@@ -0,0 +1,16 @@
+--- ./src/VBox/Runtime/r3/posix/fileio2-posix.cpp.orig
++++ ./src/VBox/Runtime/r3/posix/fileio2-posix.cpp
+@@ -165,7 +165,12 @@
+
+ /* XXX this falls back to utimes("/proc/self/fd/...",...) for older kernels/glibcs and this
+ * will not work for hardened builds where this directory is owned by root.root and mode 0500 */
+- if (futimes(RTFileToNative(hFile), aTimevals))
++ struct timespec aTimespecs[2] = {
++ { aTimevals[0].tv_sec, aTimevals[0].tv_usec * 1000 },
++ { aTimevals[1].tv_sec, aTimevals[1].tv_usec * 1000 },
++ };
++
++ if (futimens(RTFileToNative(hFile), aTimespecs))
+ {
+ int rc = RTErrConvertFromErrno(errno);
+ Log(("RTFileSetTimes(%RTfile,%p,%p,,): returns %Rrc\n", hFile, pAccessTime, pModificationTime, rc));