summaryrefslogtreecommitdiff
path: root/client/gvfsfusedaemon.c
diff options
context:
space:
mode:
authorOndrej Holy <oholy@redhat.com>2017-01-20 16:17:48 +0100
committerOndrej Holy <oholy@redhat.com>2017-01-24 12:03:01 +0100
commit2eafe5fa8ef37e91c7c2caaf8620e18083545a3e (patch)
tree4000fd70dec72e49ae93eeeed23a35c6851c2f0f /client/gvfsfusedaemon.c
parent3959a77fa4a7316024e716c9014b788870d4ed37 (diff)
downloadgvfs-2eafe5fa8ef37e91c7c2caaf8620e18083545a3e.tar.gz
fuse: Add client pid in debug messages
It is hard to debug what application is accessing fuse mount point. Let's add client pid in the debug messages.
Diffstat (limited to 'client/gvfsfusedaemon.c')
-rw-r--r--client/gvfsfusedaemon.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/client/gvfsfusedaemon.c b/client/gvfsfusedaemon.c
index 69664904..80385b40 100644
--- a/client/gvfsfusedaemon.c
+++ b/client/gvfsfusedaemon.c
@@ -104,8 +104,12 @@ log_debug (const gchar *log_domain,
const gchar *message,
gpointer unused_data)
{
+ struct fuse_context *context;
+
+ context = fuse_get_context ();
+
if (gvfs_get_debug ())
- g_print ("fuse: %s", message);
+ g_print ("fuse(%u): %s", context ? context->pid : 0, message);
}
typedef struct {