From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oa1-x30.google.com (mail-oa1-x30.google.com [IPv6:2001:4860:4864:20::30]) by sourceware.org (Postfix) with ESMTPS id E9FAD38582A1 for ; Mon, 28 Aug 2023 11:47:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E9FAD38582A1 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-1c8d2606fc9so2240649fac.0 for ; Mon, 28 Aug 2023 04:47:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1693223230; x=1693828030; h=content-transfer-encoding:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=DP2GFQ4+K4XIqJSXws8z42qYc0fvKPObgKAagX71Qs4=; b=QkstV714+yymesKJ2xelkqQGma+NbDve2lkN0OEVh1gBWUPMQi45lVnwfPPl6L7ZRs tivcS3K80OWv8/spkBYsbnGSJbJEDRCqZVWnNZ9DZMwE9iFkTEN/c3n2LflgF0EZR8Vj YIwQDUV4WC/9iomXDpXHLrqBxwajydPWDXSKJi3N8++QA/MZ8HL6rYKMFmHM7c29/jIG vK+MFPoaCzpyyLz/RlU99jKsPF1nFs6X/hziBpAsn7QSjhDUSrZ8dSJ3cpI1GwswcwOi Sirxij5zYqWKvvj8WC0ebxiIRCt+5Nk0SDqVgjuQAFHqjSUYX/SSmOvYLeQP0pfxrZvV 7J4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693223230; x=1693828030; h=content-transfer-encoding:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=DP2GFQ4+K4XIqJSXws8z42qYc0fvKPObgKAagX71Qs4=; b=Y5iFYGaX7W2nZPBRa6xD5N6bRKizWkVx7eKyCy8bMMYXMr/TteJoNCJU7GgT2Kh3GT xQovXfrNQm/H/CKPw04NdrL3XBYOEjhx6ahB8StzxMwGyit7RmIw/dtL9Jl/1w3EB6k5 O1CjtKLreRvgTImRV9Wl4FfHQR+uzzMDVqny1h6x+5KlcWlEk3edG5QmRa9/EnNZ6h8x rxBfOTHdSS2Xo+Fn13FyrxhuWuvXqDZCw8JrH7W71sDH2RAltXyzHI/q91W6qYbKq9mb y8K0TSO0/2kLdSgsQ6yxUUnKvxOOAB8wUYEBLh5GAYhPtvWkW88QmQV2kI/J0P9Pn0uJ OXLg== X-Gm-Message-State: AOJu0Yw6arqqHzKqifL5AGW1Ytjr+H9+/I2a+HB32arhYXnao4d61Wi3 GcewlryWgppJmR9rKchKgdjqJ/wjgHvYmQvTfFJQQ/6MhNo= X-Google-Smtp-Source: AGHT+IFapeRYMTEalVbZrHOBN0/rRA/F6ieSgXf3tFAVQWm3Wa6ZoIfSE+962NAzKnyekfsgpKiftgnpqo6LhHsL1uQ= X-Received: by 2002:a05:6870:9722:b0:1a9:f6ba:138a with SMTP id n34-20020a056870972200b001a9f6ba138amr5761877oaq.0.1693223230372; Mon, 28 Aug 2023 04:47:10 -0700 (PDT) MIME-Version: 1.0 References: <0b55205e-fc7c-98cf-c186-783e5c0655b0@comcast.net> In-Reply-To: From: Joshuah Hurst Date: Mon, 28 Aug 2023 13:47:00 +0200 Message-ID: Subject: Re: gawk core dumped on too many input values To: cygwin@cygwin.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Mon, Aug 28, 2023 at 1:08=E2=80=AFAM Jeremy Hetzler via Cygwin wrote: > > On Sun, Aug 27, 2023 at 2:25=E2=80=AFPM Ed Morton via Cygwin > wrote: > > > > This (original email below) turned out to be a general cygwin issue, no= t > > a gawk issue: > > > > $ LC_ALL=3DC sed 's/x/y/' $(seq 1000000) > > Segmentation fault (core dumped) > > > > $ LC_ALL=3DC grep 'foo' $(seq 1000000) > > Segmentation fault (core dumped) > > > > Seems that all commands linked with cygwin1.dll will fault if you pass th= em > a long enough arglist. > > For me, /bin/true faults on {1..258231} but not {1..258230}. > > > $ /bin/true {1..258230} > > > > > > $ /bin/true {1..258231} > > Segmentation fault (core dumped) > > > strace, which is not linked with cygwin1.dll, exits cleanly. > > > $ /bin/strace {1..300000} > > -bash: /bin/strace: Argument list too long > > > See this page [1] on maximum argument lengths. > > It would be nice to document this limit, whatever it is. Is this limit? $ getconf -a | grep -E 'ARG_MAX' _POSIX_ARG_MAX 4096 ARG_MAX 32000 > > It would also be nice to return an error to the shell on too-long arglist= . +1 --=20 Josh