Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Sep 2014 13:44:52 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 193835] New: bug in grep with -m and -A
Message-ID:  <bug-193835-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193835

            Bug ID: 193835
           Summary: bug in grep with -m and -A
           Product: Base System
           Version: 10.0-STABLE
          Hardware: Any
                OS: Any
            Status: Needs Triage
          Severity: Affects Many People
          Priority: ---
         Component: gnu
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: zhecka@gmail.com

grep segfault

create a file test.txt
-------------
text
text
<blank line>
text
text
-------------

run command: grep -m 1 -A 2 -e '^$' test.txt
> Segmentation Fault (core dumped)

in file test.txt add to end blank line

run grep again.
Result: none

Change -m1 to -m2
Result: all is ok

-- 
You are receiving this mail because:
You are the assignee for the bug.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-193835-8>