From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Jason Rumney Newsgroups: gmane.emacs.devel Subject: Re: Using `call-process-shell-command' in `process-lines' Date: Mon, 26 Nov 2007 22:17:02 +0000 Message-ID: <474B45DE.3080604@gnu.org> References: <474B2D07.6050805@gmail.com> <474B35C1.1050101@gmail.com> <474B3946.5050404@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1196115477 16008 80.91.229.12 (26 Nov 2007 22:17:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 26 Nov 2007 22:17:57 +0000 (UTC) Cc: lekktu@gmail.com, "Lennart Borgman \(gmail\)" , monnier@iro.umontreal.ca, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Nov 26 23:18:02 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1IwmH5-0007gw-CV for ged-emacs-devel@m.gmane.org; Mon, 26 Nov 2007 23:17:55 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IwmGq-0003SM-87 for ged-emacs-devel@m.gmane.org; Mon, 26 Nov 2007 17:17:40 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IwmGl-0003Rf-Jn for emacs-devel@gnu.org; Mon, 26 Nov 2007 17:17:35 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IwmGj-0003RF-U1 for emacs-devel@gnu.org; Mon, 26 Nov 2007 17:17:35 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IwmGj-0003RC-Nd for emacs-devel@gnu.org; Mon, 26 Nov 2007 17:17:33 -0500 Original-Received: from outmail1.freedom2surf.net ([194.106.33.237]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IwmGg-0004C9-BY; Mon, 26 Nov 2007 17:17:30 -0500 Original-Received: from [127.0.0.1] (i-83-67-23-108.freedom2surf.net [83.67.23.108]) by outmail1.freedom2surf.net (Postfix) with ESMTP id F28F357063; Mon, 26 Nov 2007 22:17:28 +0000 (GMT) User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) In-Reply-To: X-detected-kernel: by monty-python.gnu.org: Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:84188 Archived-At: Eli Zaretskii wrote: > Anyway, I see now that I missed something important: we already have a > wrapper for spawnve (w32proc.c:sys_spawnve), and it already tries to > quote arguments. But not in the presence of wildcards, only whitespace. The version of find that I have (4.2.20 from GnuWin32) works with the original test case, so I can't test this (other than to verify that find still works OK after the patch), but it seems like the following patch might help: *** w32proc.c.~1.73.~ 2007-10-10 22:46:40.593750000 +0100 --- w32proc.c 2007-11-26 21:33:19.609375000 +0000 *************** *** 781,787 **** variable in their environment. */ char ppid_env_var_buffer[64]; char *extra_env[] = {ppid_env_var_buffer, NULL}; ! char *sepchars = " \t"; /* We don't care about the other modes */ if (mode != _P_NOWAIT) --- 781,787 ---- variable in their environment. */ char ppid_env_var_buffer[64]; char *extra_env[] = {ppid_env_var_buffer, NULL}; ! char *sepchars = " \t*?"; /* We don't care about the other modes */ if (mode != _P_NOWAIT) *************** *** 882,888 **** /* Cygwin apps needs quoting a bit more often */ if (escape_char == '"') ! sepchars = "\r\n\t\f '"; /* do argv... */ arglen = 0; --- 882,888 ---- /* Cygwin apps needs quoting a bit more often */ if (escape_char == '"') ! sepchars = "\r\n\t\f '*?"; /* do argv... */ arglen = 0; Diffs between working revision and workfile end here.