History log of /freebsd-10-stable/usr.bin/sed/process.c
Revision Date Author Comments
# 337367 06-Aug-2018 pfg

MFC r336926:
sed: unsign some indexes to fix sign-compare warnings.

Hinted by: OpenBSD (CVS 1.32)


# 303065 20-Jul-2016 pfg

MFC r302973:
sed(1): Fix off by one introduced in r299211.

Detected by running the gsed tests.

Submitted by: Mikhail Teterin
PR: 195929


# 302244 28-Jun-2016 pfg

MFC r301138:
sed(1): convert sed to use REG_STARTEND more explicitly.

This is a followup to previous r302228, which only merged the
incomplete r300684 causing a regression.

Reported by: mi
PR: 209387
Taken from: openbsd-tech (Martijn van Duren)


# 302228 27-Jun-2016 pfg

sed(1): convert sed to use REG_STARTEND more explicitly.

Summarizing the findings in the OpenBSD list:

This solves a reproduceable issue with very recent Mesa where REG_NOTBOL
combined with a match at the begin of the string causes our regex library
to treat the word as not begin of word.

Bump __FreeBSD_version: JIC we hit the issue in recent Mesa ports.

PR: 209352, 209387 (exp-run)
Taken from: openbsd-tech (Martijn van Duren)
MFC after: 1 month


# 300555 24-May-2016 pfg

sed: rewrite the main loop.

Rewrite the main loop of the "sed s/..." command, shortening it by ten
lines and simplifying it by removing the switch statement implementing
/g, /1, and /2 separately and repetitively.

This will be needed to bring a fix from OpenBSD later.

Obtained from: OpenBSD (schwarze CVS Rev. 1.18)


# 277933 30-Jan-2015 pfg

MFC r277802, r277811:

sed: Fix resource leak and dereference after NULL.

process.c:
Protect access against NULL.

main.c:
Prevent outfile overwrite resource leak.

CID: 271181
CID: 1006930

Obtained from: NetBSD


# 277538 22-Jan-2015 pfg

MFC r276832 (partial), r277099

Avoid a warning from gcc48.
Replace __inline GNUism with the standard inline.


# 269837 11-Aug-2014 jlh

MFC r269302:

Fix relative numerical addressing (addr,+N).

As a bonus the patch untangles a bit the logic and makes the code
easier to grasp.

PR: 192108


# 277933 30-Jan-2015 pfg

MFC r277802, r277811:

sed: Fix resource leak and dereference after NULL.

process.c:
Protect access against NULL.

main.c:
Prevent outfile overwrite resource leak.

CID: 271181
CID: 1006930

Obtained from: NetBSD


# 277538 22-Jan-2015 pfg

MFC r276832 (partial), r277099

Avoid a warning from gcc48.
Replace __inline GNUism with the standard inline.


# 269837 11-Aug-2014 jlh

MFC r269302:

Fix relative numerical addressing (addr,+N).

As a bonus the patch untangles a bit the logic and makes the code
easier to grasp.

PR: 192108