From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29105 invoked by alias); 28 Feb 2010 17:49:15 -0000 Received: (qmail 29089 invoked by uid 22791); 28 Feb 2010 17:49:14 -0000 X-SWARE-Spam-Status: No, hits=-1.5 required=5.0 tests=AWL,BAYES_00,SPF_SOFTFAIL X-Spam-Check-By: sourceware.org Received: from mtaout23.012.net.il (HELO mtaout23.012.net.il) (80.179.55.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 28 Feb 2010 17:49:09 +0000 Received: from conversion-daemon.a-mtaout23.012.net.il by a-mtaout23.012.net.il (HyperSendmail v2007.08) id <0KYK00200C52XZ00@a-mtaout23.012.net.il> for gdb-patches@sourceware.org; Sun, 28 Feb 2010 19:49:06 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.70.17.203]) by a-mtaout23.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0KYK000ZMC5TFI60@a-mtaout23.012.net.il> for gdb-patches@sourceware.org; Sun, 28 Feb 2010 19:49:06 +0200 (IST) Date: Sun, 28 Feb 2010 17:49:00 -0000 From: Eli Zaretskii Subject: Re: [RFA] windows-nat.c: Cygwin: Port to Cygwin 1.7 In-reply-to: <20100228171828.GK5683@calimero.vinschen.de> To: gdb-patches@sourceware.org Reply-to: Eli Zaretskii Message-id: <83wrxxb690.fsf@gnu.org> References: <20100228150844.GH5683@calimero.vinschen.de> <837hpxcmp0.fsf@gnu.org> <20100228171828.GK5683@calimero.vinschen.de> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2010-02/txt/msg00687.txt.bz2 > Date: Sun, 28 Feb 2010 18:18:28 +0100 > From: Corinna Vinschen > > On Feb 28 19:08, Eli Zaretskii wrote: > > > Date: Sun, 28 Feb 2010 16:08:44 +0100 > > > From: Corinna Vinschen > > > > > > - The maximum path length in Cygwin is no longer MAX_PATH. Rather it > > > is PATH_MAX, which is now 4096. Actually, even paths up to 32K are > > > supported, which is the maximum path length of the underlying Windows, > > > but usually 4K is more than enough. > > > > I'd suggest not to introduce arbitrary limits. If we are going to use > > the Unicode APIs, let's support the full 32K length they give us. > > Some buffers are on the stack and would have an unnecessary big size. I don't think 32K is too much for the Windows stack (but maybe it is with Cygwin; I don't know enough to judge). In Emacs, we had until a month ago code that used alloca to allocate a 700KB structure, and it worked in the native Windows build without any problems. > PATH_MAX, 4K, is more than enough especially since the names of DLLs > are stored in a buffer which is restricted to SO_NAME_MAX_PATH_SIZE, > which is 512 bytes ATM. I wasn't thinking about DLL names, I was thinking about source file names and names of executable programs.