[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[patch #3840] fix for off by one error in src/grep.c:prpending()
From: |
Julian Foad |
Subject: |
[patch #3840] fix for off by one error in src/grep.c:prpending() |
Date: |
Mon, 13 Jun 2005 19:55:56 +0000 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b) Gecko/20050217 |
Follow-up Comment #2, patch #3840 (project grep):
This patch fixed the following seg-faults as reported by Pavol Gono when using
--max-count and --after-context:
> $ cat bla1
> 4
> 40
> $ cat bla2
> 4
> 04
> $ cat bla3
> 4
> 444
> $ egrep -m1 -A99 "^4$" bla1
> 4
> Segmentation fault
> $ egrep -m1 -A99 "^4$" bla2
> 4
> Segmentation fault
> $ egrep -m1 -A99 "^4$" bla3
> 4
> Segmentation fault
> $ egrep -m1 -A99 "^4" bla1
> 4
> $ egrep -m1 -A99 "^4" bla2
> 4
> Segmentation fault
> $ egrep -m1 -A99 "^4" bla3
> 4
> $ egrep -m1 -A99 "4$" bla1
> 4
> Segmentation fault
> $ egrep -m1 -A99 "4$" bla2
> 4
> $ egrep -m1 -A99 "4$" bla3
> 4
There are now regression tests for this in tests/foad1.sh.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/patch/?func=detailitem&item_id=3840>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [patch #3840] fix for off by one error in src/grep.c:prpending(),
Julian Foad <=