[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs/lib-src emacsclient.c ChangeLog
From: |
Dan Nicolaescu |
Subject: |
[Emacs-diffs] emacs/lib-src emacsclient.c ChangeLog |
Date: |
Wed, 10 Dec 2008 14:57:20 +0000 |
CVSROOT: /cvsroot/emacs
Module name: emacs
Changes by: Dan Nicolaescu <dann> 08/12/10 14:57:20
Modified files:
lib-src : emacsclient.c ChangeLog
Log message:
(EMACS_DAEMON): Remove definition.
(decode_options): Do not allow an empty alternate_editor on
WINDOWSNT.
(print_help_and_exit): Replace EMACS_DAEMON with WINDOWSNT.
(start_daemon_and_retry_set_socket): Likewise.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lib-src/emacsclient.c?cvsroot=emacs&r1=1.144&r2=1.145
http://cvs.savannah.gnu.org/viewcvs/emacs/lib-src/ChangeLog?cvsroot=emacs&r1=2.501&r2=2.502
Patches:
Index: emacsclient.c
===================================================================
RCS file: /cvsroot/emacs/emacs/lib-src/emacsclient.c,v
retrieving revision 1.144
retrieving revision 1.145
diff -u -b -r1.144 -r1.145
--- emacsclient.c 10 Dec 2008 09:47:07 -0000 1.144
+++ emacsclient.c 10 Dec 2008 14:57:20 -0000 1.145
@@ -54,8 +54,6 @@
# define CLOSE_SOCKET close
# define INITIALIZE()
-# define EMACS_DAEMON
-
#endif /* !WINDOWSNT */
#undef signal
@@ -586,6 +584,15 @@
arguments or expressions given. */
if (nowait && tty && argc - optind > 0)
current_frame = 1;
+
+#ifdef WINDOWSNT
+ if (alternate_editor && alternate_editor == '\0')
+ {
+ message (TRUE, "--alternate-editor argument or ALTERNATE_EDITOR variable
cannot be\n\
+an empty string");
+ exit (EXIT_FAILURE);
+ }
+#endif /* WINDOWSNT */
}
@@ -618,10 +625,10 @@
Set filename of the TCP authentication file\n\
-a, --alternate-editor=EDITOR\n\
Editor to fallback to if the server is not running\n"
-#ifdef EMACS_DAEMON
+#ifdef WINDOWSNT
" If EDITOR is the empty string, start Emacs in daemon\n\
mode and try connecting again\n"
-#endif
+#endif /* WINDOWSNT */
"\n\
Report bugs to address@hidden", progname);
exit (EXIT_SUCCESS);
@@ -1419,7 +1426,7 @@
void
start_daemon_and_retry_set_socket (void)
{
-#ifdef EMACS_DAEMON
+#ifndef WINDOWSNT
pid_t dpid;
int status;
pid_t p;
@@ -1457,7 +1464,7 @@
execvp ("emacs", d_argv);
message (TRUE, "%s: error starting emacs daemon\n", progname);
}
-#endif /* EMACS_DAEMON */
+#endif /* WINDOWSNT */
}
int
@@ -1468,7 +1475,7 @@
int i, rl, needlf = 0;
char *cwd, *str;
char string[BUFSIZ+1];
- int null_socket_name, null_server_file, start_daemon_if_needed = 0;
+ int null_socket_name, null_server_file, start_daemon_if_needed;
main_argv = argv;
progname = argv[0];
@@ -1484,12 +1491,10 @@
exit (EXIT_FAILURE);
}
-#ifdef EMACS_DAEMON
/* If alternate_editor is the empty string, start the emacs daemon
in case of failure to connect. */
start_daemon_if_needed = (alternate_editor
&& (alternate_editor[0] == '\0'));
-#endif /* EMACS_DAEMON */
if (start_daemon_if_needed)
{
/* set_socket changes the values for socket_name and
Index: ChangeLog
===================================================================
RCS file: /cvsroot/emacs/emacs/lib-src/ChangeLog,v
retrieving revision 2.501
retrieving revision 2.502
diff -u -b -r2.501 -r2.502
--- ChangeLog 10 Dec 2008 09:47:06 -0000 2.501
+++ ChangeLog 10 Dec 2008 14:57:20 -0000 2.502
@@ -1,3 +1,11 @@
+2008-12-10 Dan Nicolaescu <address@hidden>
+
+ * emacsclient.c (EMACS_DAEMON): Remove definition.
+ (decode_options): Do not allow an empty alternate_editor on
+ WINDOWSNT.
+ (print_help_and_exit): Replace EMACS_DAEMON with WINDOWSNT.
+ (start_daemon_and_retry_set_socket): Likewise.
+
2008-12-10 Juanma Barranquero <address@hidden>
* emacsclient.c [!WINDOWSNT] (EMACS_DAEMON): New define.
- [Emacs-diffs] emacs/lib-src emacsclient.c ChangeLog,
Dan Nicolaescu <=