From unknown Sun Jun 22 11:45:31 2025 X-Loop: help-debbugs@gnu.org Subject: bug#17041: Minor glitch in regex Resent-From: Edward Welbourne Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Wed, 19 Mar 2014 15:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 17041 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: 17041@debbugs.gnu.org X-Debbugs-Original-To: bug-coreutils@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.139524396931142 (code B ref -1); Wed, 19 Mar 2014 15:47:02 +0000 Received: (at submit) by debbugs.gnu.org; 19 Mar 2014 15:46:09 +0000 Received: from localhost ([127.0.0.1]:41313 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQIgx-00086A-Nm for submit@debbugs.gnu.org; Wed, 19 Mar 2014 11:46:08 -0400 Received: from eggs.gnu.org ([208.118.235.92]:51748) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQDcA-0005TL-DR for submit@debbugs.gnu.org; Wed, 19 Mar 2014 06:20:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WQDc5-0004sl-3j for submit@debbugs.gnu.org; Wed, 19 Mar 2014 06:20:50 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:50497) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQDc5-0004sg-0j for submit@debbugs.gnu.org; Wed, 19 Mar 2014 06:20:45 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53438) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQDc0-0004Sl-5m for bug-coreutils@gnu.org; Wed, 19 Mar 2014 06:20:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WQDbu-0004pu-Mz for bug-coreutils@gnu.org; Wed, 19 Mar 2014 06:20:40 -0400 Received: from mail-ee0-x22c.google.com ([2a00:1450:4013:c00::22c]:59338) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQDbt-0004pB-VD for bug-coreutils@gnu.org; Wed, 19 Mar 2014 06:20:34 -0400 Received: by mail-ee0-f44.google.com with SMTP id e49so6419189eek.31 for ; Wed, 19 Mar 2014 03:20:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cfengine.com; s=google; h=mime-version:date:message-id:subject:from:to:content-type; bh=+DC/z9si3PvTRsU1o3kxFbWWh968EdlUlCOIEhtzRqk=; b=rxz4L1HZhv8aVWCDeVVqNS4Tpm6DFpzMFMvKIKsV2At8g/44vf3a7XwdnKBKflP6O1 GS4Qv3bANZZzU4AnJSaDBXx2lwGgckafy0Ux/j0cVdRYW4N3bailPSc0Yk7anAYbKdXt UPHDH5wcOikzPjq5vM2DeGTYr+R9D5R3X0XHI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=+DC/z9si3PvTRsU1o3kxFbWWh968EdlUlCOIEhtzRqk=; b=L0E8GVbkvRKRnL8k2Jqezvp3gMiU0+OrZkKf219UOPqDpeXtWC+IGR9EKibkTQe/Yr afsM4Xqr3jeXo/ZBQ0HTEGQWLjLhTRPtnuE3VNn23Vgu1OQrc8oKSuEEerxEt1dyoK6A gEuquatRRqa8Gcm+z6Gg4XXSWb+4tT83erCOHyRdZ5+ZLJmfUTN55tuvJOFtxf9pWCfk /s2yqyXOof+ZXeLDO0S/eiFIuqb6B3rlBZvK9mqdHkA9T8x/GT7pDAEFgjGL0hmlsZaZ ljQz1g8aGPxzR+HdUiZpGS7eY/5Jh7v5OYrXXLXgN3JOoitVEva/EOi0tC3xWjXd6MNw 0O6g== X-Gm-Message-State: ALoCoQmEeY2RjbKFCJ1IZ4wdyfgBLYBT/8MqOYyVMOWibDz47F2WLfgPviqchRDZlflvnpdNiw8M MIME-Version: 1.0 X-Received: by 10.14.110.199 with SMTP id u47mr19092663eeg.74.1395224432020; Wed, 19 Mar 2014 03:20:32 -0700 (PDT) Received: by 10.15.67.197 with HTTP; Wed, 19 Mar 2014 03:20:31 -0700 (PDT) Date: Wed, 19 Mar 2014 11:20:31 +0100 Message-ID: From: Edward Welbourne Content-Type: text/plain; charset=UTF-8 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.3 (----) X-Mailman-Approved-At: Wed, 19 Mar 2014 11:46:05 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.3 (----) In the info page for "chmod invocation", node 27.2 Symbolic Modes, The format of symbolic modes is: [ugoa...][+-=]PERMS...[,...] the [+-=] is naturally read as "every character from + through =" due to the special meaning of - in a character class. I suggest [+=-] would be more apt. It is possible the same pattern is repeated elsewhere in the manual. Eddy. From unknown Sun Jun 22 11:45:31 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.503 (Entity 5.503) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Edward Welbourne Subject: bug#17041: closed (Re: bug#17041: Minor glitch in regex) Message-ID: References: <5329C607.9040203@draigBrady.com> X-Gnu-PR-Message: they-closed 17041 X-Gnu-PR-Package: coreutils Reply-To: 17041@debbugs.gnu.org Date: Wed, 19 Mar 2014 16:44:03 +0000 Content-Type: multipart/mixed; boundary="----------=_1395247443-5245-1" This is a multi-part message in MIME format... ------------=_1395247443-5245-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #17041: Minor glitch in regex which was filed against the coreutils package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 17041@debbugs.gnu.org. --=20 17041: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D17041 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1395247443-5245-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 17041-done) by debbugs.gnu.org; 19 Mar 2014 16:43:58 +0000 Received: from localhost ([127.0.0.1]:41389 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQJau-0001MB-55 for submit@debbugs.gnu.org; Wed, 19 Mar 2014 12:43:57 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59258) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQJam-0001Lq-EG for 17041-done@debbugs.gnu.org; Wed, 19 Mar 2014 12:43:49 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s2JGhbWA021032 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 19 Mar 2014 12:43:45 -0400 Received: from [10.36.116.89] (ovpn-116-89.ams2.redhat.com [10.36.116.89]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s2JGTxSX025893 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Wed, 19 Mar 2014 12:30:01 -0400 Message-ID: <5329C607.9040203@draigBrady.com> Date: Wed, 19 Mar 2014 16:29:59 +0000 From: =?UTF-8?B?UMOhZHJhaWcgQnJhZHk=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2 MIME-Version: 1.0 To: Edward Welbourne Subject: Re: bug#17041: Minor glitch in regex References: In-Reply-To: X-Enigmail-Version: 1.6 Content-Type: multipart/mixed; boundary="------------040101030703050900030305" X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 17041-done Cc: 17041-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) This is a multi-part message in MIME format. --------------040101030703050900030305 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 03/19/2014 10:20 AM, Edward Welbourne wrote: > In the info page for "chmod invocation", > node 27.2 Symbolic Modes, > > The format of symbolic modes is: > > [ugoa...][+-=]PERMS...[,...] > > > the [+-=] is naturally read as "every character from + through =" due > to the special meaning of - in a character class. I suggest [+=-] > would be more apt. It is possible the same pattern is repeated > elsewhere in the manual. [-+=] was already used in chmod --help so I went with that. I'll push the attached in your name in a while. thanks, Pádraig. --------------040101030703050900030305 Content-Type: text/x-patch; name="chmod-regex-ambiguity.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="chmod-regex-ambiguity.patch" >From 42498f9365db8be8a05a08dad43216989de32167 Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Wed, 19 Mar 2014 16:19:08 +0000 Subject: [PATCH] doc: avoid regex ambiguity in chmod mode description * man/chmod.x: s/[+-=]/[-+=]/ * doc/perm.texi (Symbolic Modes): Likewise. Fixes http://bugs.gnu.org/17041 --- doc/perm.texi | 2 +- man/chmod.x | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/perm.texi b/doc/perm.texi index 60e9160..0bccc63 100644 --- a/doc/perm.texi +++ b/doc/perm.texi @@ -148,7 +148,7 @@ their previous values, and perhaps on the current @code{umask} as well The format of symbolic modes is: @example -@r{[}ugoa@dots{}@r{][}+-=@r{]}@var{perms}@dots{}@r{[},@dots{}@r{]} +@r{[}ugoa@dots{}@r{][}-+=@r{]}@var{perms}@dots{}@r{[},@dots{}@r{]} @end example @noindent diff --git a/man/chmod.x b/man/chmod.x index e5372db..190191f 100644 --- a/man/chmod.x +++ b/man/chmod.x @@ -16,7 +16,7 @@ which can be either a symbolic representation of changes to make, or an octal number representing the bit pattern for the new mode bits. .PP The format of a symbolic mode is [\c -\fBugoa\fP.\|.\|.][[\fB+-=\fP][\fIperms\fP.\|.\|.].\|.\|.], +\fBugoa\fP.\|.\|.][[\fB-+=\fP][\fIperms\fP.\|.\|.].\|.\|.], where .I "perms" is either zero or more letters from the set -- 1.7.7.6 --------------040101030703050900030305-- ------------=_1395247443-5245-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 19 Mar 2014 15:46:09 +0000 Received: from localhost ([127.0.0.1]:41313 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQIgx-00086A-Nm for submit@debbugs.gnu.org; Wed, 19 Mar 2014 11:46:08 -0400 Received: from eggs.gnu.org ([208.118.235.92]:51748) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQDcA-0005TL-DR for submit@debbugs.gnu.org; Wed, 19 Mar 2014 06:20:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WQDc5-0004sl-3j for submit@debbugs.gnu.org; Wed, 19 Mar 2014 06:20:50 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:50497) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQDc5-0004sg-0j for submit@debbugs.gnu.org; Wed, 19 Mar 2014 06:20:45 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53438) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQDc0-0004Sl-5m for bug-coreutils@gnu.org; Wed, 19 Mar 2014 06:20:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WQDbu-0004pu-Mz for bug-coreutils@gnu.org; Wed, 19 Mar 2014 06:20:40 -0400 Received: from mail-ee0-x22c.google.com ([2a00:1450:4013:c00::22c]:59338) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQDbt-0004pB-VD for bug-coreutils@gnu.org; Wed, 19 Mar 2014 06:20:34 -0400 Received: by mail-ee0-f44.google.com with SMTP id e49so6419189eek.31 for ; Wed, 19 Mar 2014 03:20:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cfengine.com; s=google; h=mime-version:date:message-id:subject:from:to:content-type; bh=+DC/z9si3PvTRsU1o3kxFbWWh968EdlUlCOIEhtzRqk=; b=rxz4L1HZhv8aVWCDeVVqNS4Tpm6DFpzMFMvKIKsV2At8g/44vf3a7XwdnKBKflP6O1 GS4Qv3bANZZzU4AnJSaDBXx2lwGgckafy0Ux/j0cVdRYW4N3bailPSc0Yk7anAYbKdXt UPHDH5wcOikzPjq5vM2DeGTYr+R9D5R3X0XHI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=+DC/z9si3PvTRsU1o3kxFbWWh968EdlUlCOIEhtzRqk=; b=L0E8GVbkvRKRnL8k2Jqezvp3gMiU0+OrZkKf219UOPqDpeXtWC+IGR9EKibkTQe/Yr afsM4Xqr3jeXo/ZBQ0HTEGQWLjLhTRPtnuE3VNn23Vgu1OQrc8oKSuEEerxEt1dyoK6A gEuquatRRqa8Gcm+z6Gg4XXSWb+4tT83erCOHyRdZ5+ZLJmfUTN55tuvJOFtxf9pWCfk /s2yqyXOof+ZXeLDO0S/eiFIuqb6B3rlBZvK9mqdHkA9T8x/GT7pDAEFgjGL0hmlsZaZ ljQz1g8aGPxzR+HdUiZpGS7eY/5Jh7v5OYrXXLXgN3JOoitVEva/EOi0tC3xWjXd6MNw 0O6g== X-Gm-Message-State: ALoCoQmEeY2RjbKFCJ1IZ4wdyfgBLYBT/8MqOYyVMOWibDz47F2WLfgPviqchRDZlflvnpdNiw8M MIME-Version: 1.0 X-Received: by 10.14.110.199 with SMTP id u47mr19092663eeg.74.1395224432020; Wed, 19 Mar 2014 03:20:32 -0700 (PDT) Received: by 10.15.67.197 with HTTP; Wed, 19 Mar 2014 03:20:31 -0700 (PDT) Date: Wed, 19 Mar 2014 11:20:31 +0100 Message-ID: Subject: Minor glitch in regex From: Edward Welbourne To: bug-coreutils@gnu.org Content-Type: text/plain; charset=UTF-8 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.3 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Wed, 19 Mar 2014 11:46:05 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.3 (----) In the info page for "chmod invocation", node 27.2 Symbolic Modes, The format of symbolic modes is: [ugoa...][+-=]PERMS...[,...] the [+-=] is naturally read as "every character from + through =" due to the special meaning of - in a character class. I suggest [+=-] would be more apt. It is possible the same pattern is repeated elsewhere in the manual. Eddy. ------------=_1395247443-5245-1--