From: Eli Zaretskii <eliz@gnu.org>
To: Evgeny Fraimovitch <johnlen7@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: [PATCH] Make emacsclientw -a usable
Date: Sun, 19 Jul 2015 21:32:03 +0300 [thread overview]
Message-ID: <83twt03snw.fsf@gnu.org> (raw)
In-Reply-To: <CABytfPQiQJHnKgLL1yqwk6h=hgyFgpczE9rw5TeSv4e2VJnuyw@mail.gmail.com>
> From: Evgeny Fraimovitch <johnlen7@gmail.com>
> Date: Sat, 18 Jul 2015 22:25:31 +0000
>
> Currently the emacsclientw (the non-console version of Win32 emacs client) pops
> up a modal message box if emacs server is not running even if there is an
> alternate specified. This makes the -a option (with or without an argument)
> somewhat useless, since the user is greeted by a modal message box,
> interrupting the workflow.
> The attached patch supresses the modal message box (only in Win32 and only in
> the non-console client) if there is an alternate editor specified - the user
> will only get an error message if the alternative fails too.
>
> The patch is produced against today's emacs master.
Thanks.
> --- a/lib-src/emacsclient.c
> +++ b/lib-src/emacsclient.c
> @@ -968,7 +968,14 @@ set_tcp_socket (const char *local_server_file)
> /* Set up the socket. */
> if (connect (s, (struct sockaddr *) &server, sizeof server) < 0)
> {
> - sock_err_message ("connect");
> + /*Since we have an alternate to try out this is not an error yet
> + popping out a modal dialog at this stage would make -a option totally
> + useless for emacsclientw - the user will still get an error message
> + if the alternate editor fails*/
> +#ifdef WINDOWSNT
> + if(!(w32_window_app() && alternate_editor))
> +#endif
> + sock_err_message ("connect");
> return INVALID_SOCKET;
> }
What about the other call to sock_err_message in that function,
doesn't it need to be handled the same way in emacsclientw?
next prev parent reply other threads:[~2015-07-19 18:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-18 22:25 [PATCH] Make emacsclientw -a usable Evgeny Fraimovitch
2015-07-19 18:32 ` Eli Zaretskii [this message]
2015-07-19 19:15 ` Evgeny Fraimovitch
2015-07-27 22:33 ` Evgeny Fraimovitch
2015-07-28 2:32 ` Eli Zaretskii
2015-08-02 14:50 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83twt03snw.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=johnlen7@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.