-fix minor leaks in gnunet-arm (#3105)
authorChristian Grothoff <christian@grothoff.org>
Sat, 9 Nov 2013 20:21:48 +0000 (20:21 +0000)
committerChristian Grothoff <christian@grothoff.org>
Sat, 9 Nov 2013 20:21:48 +0000 (20:21 +0000)
src/arm/gnunet-arm.c

index a492fac5b14ea502888ec2fb75463c26dce615d1..b960d0292f3f306058998f2661a6ea443feb0f17 100644 (file)
@@ -417,7 +417,9 @@ init_callback (void *cls,
 
   if (GNUNET_ARM_REQUEST_SENT_OK != rs)
   {
-    GNUNET_asprintf (&msg, _("Failed to send a request to start the `%s' service: %%s\n"), init);
+    GNUNET_asprintf (&msg,
+                     _("Failed to send a request to start the `%s' service: %%s\n"),
+                     init);
     FPRINTF (stdout, msg, req_string (rs));
     GNUNET_free (msg);
     GNUNET_SCHEDULER_shutdown ();
@@ -436,6 +438,7 @@ init_callback (void *cls,
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Service %s [re]started successfully\n",
              init);
+  GNUNET_free (init);
   init = NULL;
   GNUNET_SCHEDULER_add_now (&action_loop, NULL);
 }
@@ -482,7 +485,9 @@ term_callback (void *cls,
   }
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-             "Service %s stopped successfully\n", term);
+             "Service %s stopped successfully\n",
+              term);
+  GNUNET_free (term);
   term = NULL;
   GNUNET_SCHEDULER_add_now (&action_loop, NULL);
 }