On 08/12/16 23:10, Glenn Morris wrote: > Reuben Thomas wrote: > >> The attached patch adds support to emacsclient for command-line options >> when specifying the alternate editor, so that for example one can now say: >> >> ALTERNATE_EDITOR="emacs -Q -nw" > Obvious question: what happens if eg one wants to specify an absolute > file name for the alternate editor, and it contains spaces? I've modified my patch to cope with this case. Rather than write a general escaping parser, or even one that just copes with escaping quotes (likely to be complex and buggy in C; and I couldn't find code I could easily lift from elsewhere), I simply allow " as a delimiter as well as space for quotes. Escaping quotes is not supported. This suffices to cope with the common case on Windows of needing to quote a path containing spaces. It also copes with other simple cases. Is this sufficient? Updated patch attached. -- https://rrt.sc3d.org