From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: call-process having problems with a big total length of arguments under Windows Date: Sun, 10 Mar 2013 18:21:52 +0200 Message-ID: <83ppz7w7hb.fsf@gnu.org> References: Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1362932529 25033 80.91.229.3 (10 Mar 2013 16:22:09 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 10 Mar 2013 16:22:09 +0000 (UTC) Cc: emacs-devel@gnu.org To: Mathias Dahl Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Mar 10 17:22:33 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UEj16-0004Hf-MI for ged-emacs-devel@m.gmane.org; Sun, 10 Mar 2013 17:22:32 +0100 Original-Received: from localhost ([::1]:48375 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UEj0k-00063Y-GZ for ged-emacs-devel@m.gmane.org; Sun, 10 Mar 2013 12:22:10 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:37165) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UEj0h-00063T-0j for emacs-devel@gnu.org; Sun, 10 Mar 2013 12:22:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UEj0e-00016t-7U for emacs-devel@gnu.org; Sun, 10 Mar 2013 12:22:06 -0400 Original-Received: from mtaout22.012.net.il ([80.179.55.172]:42270) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UEj0d-00016H-VW for emacs-devel@gnu.org; Sun, 10 Mar 2013 12:22:04 -0400 Original-Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MJG00J00DE9X000@a-mtaout22.012.net.il> for emacs-devel@gnu.org; Sun, 10 Mar 2013 18:22:02 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJG00JX2DGP6AJ0@a-mtaout22.012.net.il>; Sun, 10 Mar 2013 18:22:01 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: Solaris 10 X-Received-From: 80.179.55.172 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:157697 Archived-At: > From: Mathias Dahl > Date: Sun, 10 Mar 2013 14:19:54 +0100 > > PS. I found a limit on the number of arguments I can use if the > argument is one character: > > (apply 'call-process > (append (list > "ping" > nil t nil) > (make-list 16369 "1"))) > > Now, if I double the length of each argument I can get higher than > 16369 characters in total: > > (apply 'call-process > (append (list > "ping" > nil t nil) > (make-list 10912 "12"))) > > So, it's not simply the total amount, but a combination of the number > of arguments on the length of those arguments. > > Any ideas? The API used to invoke subprocesses on MS-Windows imposes a hard limit of 32KB on the length of the command line passed to the subprocess. This length includes all the arguments your Lisp program conses, plus the blank characters that delimit each argument from the next. Does this explain what you see?