[gvfs] mtp: Use a less spamming function for the heartbeat call



commit 47b10c6a94a08efc7ce84e121641a4f77bffd5e0
Author: Philip Langdale <philipl overt org>
Date:   Wed Sep 7 08:56:59 2016 -0700

    mtp: Use a less spamming function for the heartbeat call
    
    Dump_Device_Info spews a lot of stuff to stderr which ends up
    getting captured on systemd based distros.
    
    Let's use a simpler function that doesn't spew everywhere.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=770916

 daemon/gvfsbackendmtp.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/daemon/gvfsbackendmtp.c b/daemon/gvfsbackendmtp.c
index 09eed94..2338235 100644
--- a/daemon/gvfsbackendmtp.c
+++ b/daemon/gvfsbackendmtp.c
@@ -813,7 +813,10 @@ static gboolean
 mtp_heartbeat (GVfsBackendMtp *backend)
 {
   if (g_mutex_trylock (&backend->mutex)) {
-    LIBMTP_Dump_Device_Info(backend->device);
+    char *name = LIBMTP_Get_Friendlyname (backend->device);
+    if (name) {
+      free (name);
+    }
     g_mutex_unlock (&backend->mutex);
   }
   return TRUE;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]