NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
bin/41136: \<word search doesn't work in vi
>Number: 41136
>Category: bin
>Synopsis: \<word search doesn't work in vi
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Apr 04 00:15:00 +0000 2009
>Originator: Brian Marcotte
>Release: 5.0 RC3
>Organization:
Panix
>Environment:
NetBSD panix2.panix.com 5.0_RC3 NetBSD 5.0_RC3 (PANIX-XEN3U-USER) #0: Mon Mar
23 00:30:15 EDT 2009
root%juggler.panix.com@localhost:/misc3/obj/misc2/devel/netbsd/5.0-RC3/src/sys/arch/i386/compile/PANIX-XEN3U-USER
i386
>Description:
\<word (beginning of word) search doesn't work in vi. It seems to ignore the \<.
word\> (end-of word) DOES work though.
>How-To-Repeat:
echo "aaaaa aaaaa aaa" > somefile
vi somefile
When in vi, search for \<aaa
It should bring you to the beginning of one of those words, but instead will go
to any set of "aaa".
>Fix:
In src/dist/nvi/regex/regex2.h, OUT is now defined as WEOF which is -1.
Later in src/dist/nvi/regex/engine.c, OUT is used as a base to define BOL, EOL,
BOW, etc. The important part is that BOL=OUT+1 (or 0).
In a couple different functions, flagch is initialized to 0 probably assuming
none BOL, EOL, etc. could ever equal 0.
Presumably, OUT needs to be defined to something outside the normal character
range.
Home |
Main Index |
Thread Index |
Old Index