]> git.eshelyaron.com Git - emacs.git/commitdiff
* emacsclient.c (main): Avoid dangling 'if'.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 25 Feb 2011 23:39:18 +0000 (15:39 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 25 Feb 2011 23:39:18 +0000 (15:39 -0800)
lib-src/ChangeLog
lib-src/emacsclient.c

index 5b8033d2aec88556abb272918f4687d52a0a7b0e..d1203b2ff962ace0341e77d749b01f49bd802d2f 100644 (file)
@@ -1,5 +1,7 @@
 2011-02-25  Paul Eggert  <eggert@cs.ucla.edu>
 
+       * emacsclient.c (main): Avoid dangling 'if'.
+
        * emacsclient.c: Redo local variables to avoid shadowing problems.
        (message, socket_status, start_daemon_and_retry_set_socket):
        Rename locals.
index 070d6370714f759e9c2f5aa3be58d243ba8da334..b0087c124ec95e3b225b6b468baed2309bb24188 100644 (file)
@@ -1543,21 +1543,21 @@ main (int argc, char **argv)
       null_server_file = (server_file == NULL);
     }
 
-  if ((emacs_socket = set_socket (alternate_editor
-                                 || start_daemon_if_needed)) == INVALID_SOCKET)
-    if (start_daemon_if_needed)
-      {
-       /* Reset socket_name and server_file if they were NULL
-          before the set_socket call.  */
-       if (null_socket_name)
-         socket_name = NULL;
-       if (null_server_file)
-         server_file = NULL;
-
-       start_daemon_and_retry_set_socket ();
-      }
-    else
-      fail ();
+  emacs_socket = set_socket (alternate_editor || start_daemon_if_needed);
+  if (emacs_socket == INVALID_SOCKET)
+    {
+      if (! start_daemon_if_needed)
+       fail ();
+
+      /* Reset socket_name and server_file if they were NULL
+        before the set_socket call.  */
+      if (null_socket_name)
+       socket_name = NULL;
+      if (null_server_file)
+       server_file = NULL;
+
+      start_daemon_and_retry_set_socket ();
+    }
 
   cwd = get_current_dir_name ();
   if (cwd == 0)