ListNames and ListQueuedOwners updated to work with new kdbus
[platform/upstream/dbus.git] / tools / dbus-launch-x11.c
index 0d37134..c7e3330 100644 (file)
@@ -248,7 +248,7 @@ init_x_atoms (Display *display)
   user = getpwuid (getuid ());
   if (user == NULL)
     {
-      verbose ("Could not determine the user informations; aborting X11 integration.\n");
+      verbose ("Could not determine user information; aborting X11 integration.\n");
       return FALSE;
     }
   user_name = xstrdup(user->pw_name);
@@ -405,6 +405,7 @@ set_address_in_file (char *address, pid_t pid, Window wid)
     return FALSE;
 
   f = fopen (session_file, "w");
+  free (session_file);
   if (f == NULL)
     return FALSE;               /* some kind of error */
   fprintf (f,
@@ -421,7 +422,6 @@ set_address_in_file (char *address, pid_t pid, Window wid)
            address, (long)pid, (long)wid);
 
   fclose (f);
-  free (session_file);
 
   return TRUE;
 }