summaryrefslogtreecommitdiff
path: root/monitor
diff options
context:
space:
mode:
authorSam Thursfield <sam@afuera.me.uk>2019-08-06 21:19:57 +0200
committerBastien Nocera <hadess@hadess.net>2019-08-08 19:21:29 +0000
commit5af74b51778f90c24264c6edf04b1a403c9baa33 (patch)
tree1b17c0d9e472dc555ca57eb8b9746615e8df3b29 /monitor
parent3b1188ce04910e91c7cec8afed7a30a9ee052cd3 (diff)
downloadgvfs-5af74b51778f90c24264c6edf04b1a403c9baa33.tar.gz
afc: Use g_debug() instead of g_print() for log output
Daemons shouldn't be printing directly to stdout, but should be using the normal GLib logging system. The messages output by this daemon will not show by default, but setting `G_MESSAGES_DEBUG=GVFS-AFC` in the environment will cause them to appear.
Diffstat (limited to 'monitor')
-rw-r--r--monitor/afc/afcvolume.c2
-rw-r--r--monitor/afc/afcvolumemonitor.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/monitor/afc/afcvolume.c b/monitor/afc/afcvolume.c
index 5f52cf16..319e1dfe 100644
--- a/monitor/afc/afcvolume.c
+++ b/monitor/afc/afcvolume.c
@@ -334,7 +334,7 @@ g_vfs_afc_volume_mount (GVolume *volume,
ActivationMountOp *data;
GFile *root;
- g_print ("g_vfs_afc_volume_mount (can_mount=%d uuid=%s)\n",
+ g_debug ("g_vfs_afc_volume_mount (can_mount=%d uuid=%s)",
g_vfs_afc_volume_can_mount (volume),
afc_volume->uuid);
diff --git a/monitor/afc/afcvolumemonitor.c b/monitor/afc/afcvolumemonitor.c
index ad9007c5..953947e4 100644
--- a/monitor/afc/afcvolumemonitor.c
+++ b/monitor/afc/afcvolumemonitor.c
@@ -26,7 +26,7 @@ g_vfs_afc_monitor_create_volume (GVfsAfcVolumeMonitor *self,
{
GVfsAfcVolume *volume = NULL;
- g_print ("creating volume for device uuid '%s'\n", uuid);
+ g_debug ("creating volume for device uuid '%s'\n", uuid);
/* Only add the house arrest volume, the default AFC service
* doesn't contain anything that users should modify */
@@ -63,7 +63,7 @@ g_vfs_afc_monitor_remove_volume (GVfsAfcVolumeMonitor *self,
volume = find_volume_by_uuid (self, uuid);
while (volume != NULL)
{
- g_print ("removing volume for device uuid '%s'\n", uuid);
+ g_debug ("removing volume for device uuid '%s'\n", uuid);
self->volumes = g_list_remove (self->volumes, volume);
g_signal_emit_by_name (self, "volume-removed", volume);
g_object_unref (volume);
@@ -102,7 +102,7 @@ g_vfs_afc_volume_monitor_constructor (GType type, guint ncps,
idevice_event_subscribe(g_vfs_afc_monitor_idevice_event, self);
- g_print ("Volume monitor alive\n");
+ g_debug ("Volume monitor alive\n");
return G_OBJECT(self);
}