From: Dave Chinner <david@fromorbit.com>
To: Jeff Mahoney <jeffm@suse.com>
Cc: fstests@vger.kernel.org
Subject: Re: [PATCH 2/7] filter: fix assumed whitespace in _filefrag_filter regex
Date: Wed, 23 Jan 2019 15:16:28 +1100 [thread overview]
Message-ID: <20190123041628.GP6173@dastard> (raw)
In-Reply-To: <02910403-e6c2-5af8-ebe6-c7fe19b7c02a@suse.com>
On Tue, Jan 22, 2019 at 08:38:17PM -0500, Jeff Mahoney wrote:
> On 1/21/19 5:51 PM, Dave Chinner wrote:
> > On Mon, Jan 21, 2019 at 11:33:11AM -0500, jeffm@suse.com wrote:
> >> From: Jeff Mahoney <jeffm@suse.com>
> >>
> >> The regex assumes there will be whitespace after the .. in the ranges
> >> and, with larger offsets, there may not be any.
> >
> > Does more than this, right?
>
> I suppose. It converts the interpreted .. into a literal .., which I
> believe was the original intent.
>
> >> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
> >> ---
> >> common/filter | 2 +-
> >> 1 file changed, 1 insertion(+), 1 deletion(-)
> >>
> >> diff --git a/common/filter b/common/filter
> >> index ed082d24..b4443a34 100644
> >> --- a/common/filter
> >> +++ b/common/filter
> >> @@ -532,7 +532,7 @@ _filter_filefrag()
> >> next
> >> }
> >> ($ext, $logical, $physical, $length) =
> >> - (/^\s*(\d+):\s+(\d+)..\s+\d+:\s+(\d+)..\s+\d+:\s+(\d+):/)
> >> + (/^\s*(\d+):\s+(\d+)\.\.\s*\d+:\s+(\d+)\.\.\s*\d+:\s+(\d+):/)
> >
> > This is escaping "..", too, isn't it?
>
> Yes, but what else could the .. in the original regex have been
> referring to? I don't recall seeing any other filefrag format that
> would match otherwise.
Neither do I. My point was it was a change that was not documented
in the commit message and so there might be something I was missing.
> I don't have a problem documenting it further, though.
That'd be great, thanks!
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
next prev parent reply other threads:[~2019-01-23 4:16 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-21 16:33 [PATCH 1/7] btrfs/010: don't run without /sys/fs/btrfs jeffm
2019-01-21 16:33 ` [PATCH 2/7] filter: fix assumed whitespace in _filefrag_filter regex jeffm
2019-01-21 22:51 ` Dave Chinner
2019-01-23 1:38 ` Jeff Mahoney
2019-01-23 4:16 ` Dave Chinner [this message]
2019-01-21 16:33 ` [PATCH 3/7] filter: add support for old filefrag -v jeffm
2019-01-21 22:53 ` Dave Chinner
2019-01-23 1:38 ` Jeff Mahoney
2019-01-21 16:33 ` [PATCH 4/7] btrfs: require feature raid56 for raid56 tests jeffm
2019-01-22 22:39 ` Filipe Manana
2019-01-21 16:33 ` [PATCH 5/7] btrfs/023: skip trying to test raid56 without kernel support jeffm
2019-01-22 22:40 ` Filipe Manana
2019-01-21 16:33 ` [PATCH 6/7] btrfs/131: require support for free-space-tree jeffm
2019-01-22 22:41 ` Filipe Manana
2019-01-21 16:33 ` [PATCH 7/7] check: move test exclusion handling to _prepare_test_list jeffm
2019-01-21 23:09 ` Dave Chinner
2019-01-23 1:59 ` Jeff Mahoney
2019-01-22 22:38 ` [PATCH 1/7] btrfs/010: don't run without /sys/fs/btrfs Filipe Manana
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190123041628.GP6173@dastard \
--to=david@fromorbit.com \
--cc=fstests@vger.kernel.org \
--cc=jeffm@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.