openbsd-ports/x11/dbus/patches/patch-dbus_dbus-sysdeps-util-unix_c
2012-08-15 08:03:43 +00:00

25 lines
848 B
Plaintext

$OpenBSD: patch-dbus_dbus-sysdeps-util-unix_c,v 1.4 2012/08/15 08:03:43 ajacoutot Exp $
Don't try to use /proc; we don't provide a replacement because this
function is only called once for logging purpose, its return code is not
checked and as the code says: "This string <...> may not be trusted".
--- dbus/dbus-sysdeps-util-unix.c.orig Thu Jun 28 16:49:23 2012
+++ dbus/dbus-sysdeps-util-unix.c Wed Aug 15 09:51:07 2012
@@ -1104,6 +1104,7 @@ _dbus_command_for_pid (unsigned long pid,
int max_len,
DBusError *error)
{
+#ifndef __OpenBSD__
/* This is all Linux-specific for now */
DBusString path;
DBusString cmdline;
@@ -1163,4 +1164,7 @@ fail:
_dbus_string_free (&cmdline);
_dbus_string_free (&path);
return FALSE;
+#else // OpenBSD
+ return FALSE;
+#endif
}