| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
[WINDOWSNT] (w32_find_emacs_process, w32_give_focus): New functions.
(main) [WINDOWSNT]: Remove code to release the focus; call
w32_give_focus instead.
|
| |
|
| |
|
|
|
|
|
| |
(execvp) [WINDOWSNT]: Redefine to `w32_execvp'.
(fail): Remove Windows-specific fix (subsumed in w32_execvp).
|
|
|
|
|
|
|
|
| |
(message): Remove leftover code.
(get_server_config): Set emacs_pid. Don't allow Emacs to grab the focus yet;
emacsclient can still display an informational message before sending requests
to Emacs.
(main): Allow Emacs to grab the focus. Simplify message() call.
|
|
|
|
|
|
| |
escapes, and flush the result.
(set_tcp_socket): Make the message for non-local connections informational
rather than an error.
|
| |
|
|
|
|
| |
slashes.
|
| |
|
|
|
|
| |
to improve alignment in message boxes.
|
|
|
|
|
|
|
|
|
| |
[WINDOWSNT]: Include <windows.h>.
(w32_check_console_app): New function.
(message): New function.
(decode_options, print_help_and_exit, fail, main, initialize_sockets,
get_server_config, set_tcp_socket, set_local_socket, set_socket):
Use message().
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
if it doesn't exist on HOME, even if HOME is defined.
|
|
|
|
| |
On Windows, try to force the Emacs frame to the foreground.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(decode_options): Don't get EMACS_SERVER_FILE here, it could override command
line options.
(decode_options) [! NO_SOCKETS_IN_FILE_SYSTEM]: Don't parse "-s" option.
(fail): Don't check for missing arguments, it is now done in set_socket.
(file_name_absolute_p): New function (loosely based on the one in fileio.c).
(initialize_sockets): Don't check for duplicate loading of Winsock.
(get_server_config): Only try relative paths in the default directory locations.
(set_tcp_socket): Don't call INITIALIZE(). Warn when connecting to a remote
server.
(set_socket): Call INITIALIZE(). Search explicit command-line arguments, then
environment variable EMACS_SERVER_FILE, then implicit socket paths, before
trying the alternate editor.
(main): Use file_name_absolute_p.
|
| |
|
|
|
|
|
|
|
| |
[!WINDOWSNT]: Include <netinet/in.h> if available.
[HAVE_SOCKETS]: Also require HAVE_INET_SOCKETS.
(IOCTL, IOCTL_BOOL_ARG): Remove.
(set_tcp_socket): Don't set the socket in blocking mode. Remove c_arg.
|
|
|
|
| |
(otherwise .BAT scripts can't run).
|
|
|
|
| |
(close_winsock): Declare as __cdecl.
|
|
|
|
|
| |
(set_tcp_socket): Prefer O_NONBLOCK, then O_NDELAY, then FIONBIO to set the
socket in non-blocking mode.
|
|
|
|
|
|
|
| |
[!WINDOWSNT] <top level>: Include <netinet/in.h> and <sys/ioctl.h>.
(INVALID_SOCKET): Define.
(initialize_sockets): Put #endif at the right place.
(set_local_socket): Use progname, not argv[0].
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(SEND_STRING, SEND_QUOTED, HSOCKET, CLOSE_SOCKET, IOCTL, INITIALIZE): New
macros.
(IOCTL_BOOL_ARG): New typedef.
(server_file): New global variable.
(longopts): New option --server-file.
(decode_options): Process new option --server-file and environment variable
EMACS_SERVER_FILE.
(print_help_and_exit): Document new option.
(fail): If no connection available and no alternate editor, suggest using
options to make them explicit.
(AUTH_KEY_LENGTH, SEND_BUFFER_SIZE): New constants.
(send_buffer, sblen): New variables.
(send_to_emacs): New function to buffer output and send it with send().
(quote_file_name): Use SEND_STRING.
(close_winsock, initialize_sockets): New functions to load and unload Winsock.
(get_server_config, set_tcp_socket): New functions to create and set up TCP
sockets.
(set_local_socket): New function to create and set up Unix socket (code moved
from previous implementation).
(set_socket): New function to chose between TCP and Unix sockets.
(main): Use SEND_STRING and SEND_QUOTED. Most code moved to set_local_socket.
Use set_socket. Get answers from server.el with recv(), not file stream
functions.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* emacsclient.c (print_help_and_exit): Likewise.
* xterm.c (x_connection_closed, x_error_quitter): Mark as NO_RETURN.
* textprop.c (text_read_only): Likewise.
* lread.c (end_of_file_error): Likewise.
* lisp.h (circular_list_error, memory_full, buffer_memory_full):
Likewise.
* eval.c (unwind_to_catch): Likewise.
* buffer.h (buffer_slot_type_mismatch): Likewise.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Likewise, replace 1 with `EXIT_FAILURE'.
(main): Use `EXIT_SUCCESS' or `EXIT_FAILURE' for return value.
|
| |
|
|
|
|
| |
Look for relative socket names in the /tmp dir rather than in cwd.
|
|
|
|
| |
so the error message comes from socket_status.
|
|
|
|
|
| |
Only try su-fallback if the socket name was not explicit.
Check socket name length in su-fallback case as well.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
returning it. Fix the return type accordingly.
(main): Under --eval, don't fail if left with additional
arguments after decoding options. Quote file names.
|
| |
|
|
|
|
|
|
|
| |
(longopts, decode_options, print_help_and_exit):
Handle --socket-name argument.
(main): Use socket_name.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
lines for readability.
(decode_options): Don't call print_help_and_exit in default case. Print version
information to stdout.
(main): Don't call print_help_and_exit.
|
|
|
|
| |
be found.
|
| |
|
| |
|