summaryrefslogtreecommitdiff
path: root/src/udisksdaemonutil.c
diff options
context:
space:
mode:
authorDavid Zeuthen <zeuthen@gmail.com>2012-10-03 10:12:14 -0400
committerDavid Zeuthen <zeuthen@gmail.com>2012-10-03 10:12:14 -0400
commit2174256413b05e1f423c046c596ef981b52e7d82 (patch)
treeca658d827f8a861c3862212f5ec0314ec2ba253d /src/udisksdaemonutil.c
parentfd9277e38cd59bcfdc9b064b257e77a69f86511f (diff)
parent56b03b867e21610edcd4a9335e46f6897e1ccb3f (diff)
downloadudisks-2174256413b05e1f423c046c596ef981b52e7d82.tar.gz
Merge branch 'master' into wip/mdraidwip/mdraid
Diffstat (limited to 'src/udisksdaemonutil.c')
-rw-r--r--src/udisksdaemonutil.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/udisksdaemonutil.c b/src/udisksdaemonutil.c
index 0ad2185..a2925d8 100644
--- a/src/udisksdaemonutil.c
+++ b/src/udisksdaemonutil.c
@@ -42,6 +42,7 @@
#include "udiskslinuxdriveobject.h"
#if defined(HAVE_LIBSYSTEMD_LOGIN)
+#include <systemd/sd-daemon.h>
#include <systemd/sd-login.h>
#endif
@@ -996,7 +997,7 @@ udisks_daemon_util_escape (const gchar *str)
}
/**
- * udisks_daemon_util_on_other_seat:
+ * udisks_daemon_util_on_same_seat:
* @daemon: A #UDisksDaemon.
* @object: The #GDBusObject that the call is on or %NULL.
* @process: The process to check for.
@@ -1024,6 +1025,10 @@ udisks_daemon_util_on_same_seat (UDisksDaemon *daemon,
UDisksObject *drive_object = NULL;
UDisksDrive *drive = NULL;
+ /* if we haven't booted with systemd, assume it's always the same seat */
+ if (sd_booted () <= 0)
+ return TRUE;
+
if (UDISKS_IS_LINUX_BLOCK_OBJECT (object))
{
UDisksLinuxBlockObject *linux_block_object;
@@ -1135,9 +1140,10 @@ udisks_daemon_util_hexdump_debug (gconstpointer data, gsize len)
/* ---------------------------------------------------------------------------------------------------- */
/**
+ * udisks_daemon_util_file_set_contents:
* @filename: (type filename): Name of a file to write @contents to, in the GLib file name encoding.
* @contents: (array length=length) (element-type guint8): String to write to the file.
- * @length: Length of @contents, or -1 if @contents is a NUL-terminated string.
+ * @contents_len: Length of @contents, or -1 if @contents is a NUL-terminated string.
* @mode_for_new_file: Mode for new file.
* @error: Return location for a #GError, or %NULL.
*