History log of /freebsd/usr.bin/sed/process.c (Results 76 – 100 of 138)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: release/4.5.0_cvs, release/4.4.0_cvs
# e74bf75f 13-Dec-2001 Mark Murray <markm@FreeBSD.org>

WARNS=2 partial fix; use NO_WERROR to protect against some hard-to-fix warnings.

Use __FBSDID(), kill register keyword.


# 8e33c0a0 24-Jul-2001 David E. O'Brien <obrien@FreeBSD.org>

Expand xmalloc in-place, along with xrealloc; which wasn't even ANSI in its
implementation.


Revision tags: release/4.3.0_cvs, release/4.3.0, release/4.2.0, release/4.1.1_cvs, release/4.1.0, release/3.5.0_cvs, release/4.0.0_cvs, release/3.4.0_cvs, release/3.3.0_cvs
# c3aac50f 28-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


Revision tags: release/3.2.0
# 96846ff6 26-Apr-1999 Warner Losh <imp@FreeBSD.org>

More egcs warning fixes:
o main returns int not void
o use return 0 at end of main when needed
o use braces to avoid potentially ambiguous else
o don't default to type int
o #ifdef 0 -> #if 0

R

More egcs warning fixes:
o main returns int not void
o use return 0 at end of main when needed
o use braces to avoid potentially ambiguous else
o don't default to type int
o #ifdef 0 -> #if 0

Reviewed by: obrien and chuckr

show more ...


Revision tags: release/3.1.0, release/3.0.0, release/2.2.8
# 2806aab7 07-Dec-1998 Archie Cobbs <archie@FreeBSD.org>

Compile -Wall


Revision tags: release/2.2.7
# 3492193d 29-Apr-1998 Andrey A. Chernov <ache@FreeBSD.org>

Make 'y' command 8bit clean
PR: 6458


Revision tags: release/2.2.6, release/2.2.5_cvs
# 73a08bb2 11-Aug-1997 Philippe Charnier <charnier@FreeBSD.org>

Remove local redefinition for err(). Add usage().


Revision tags: release/2.2.2_cvs, release/2.2.1_cvs, release/2.2.0, release/2.1.7_cvs, release/2.1.6_cvs, release/2.1.6.1, release/2.1.5_cvs
# 726aebe5 11-Aug-1996 Andrey A. Chernov <ache@FreeBSD.org>

Localize it
8bit cleanup


Revision tags: release/2.1.0_cvs
# ce19262d 16-Aug-1995 Jordan K. Hubbard <jkh@FreeBSD.org>

Merge various fixes from NetBSD. This will allow the WordPerfect for
SCO installation to run all the way through (some POSIX fixes).


Revision tags: release/2.0.5_cvs
# 7799f52a 30-May-1995 Rodney W. Grimes <rgrimes@FreeBSD.org>

Remove trailing whitespace.


# 30ad8d93 06-Feb-1995 Jean-Marc Zucconi <jmz@FreeBSD.org>

Correct a bug in the P function: according to 7th edition UNIX (tm), the
newline must be part of the pattern space i.e. `echo a|sed -e P' must print
a
a
and not
aa
This is consistent with gnu sed, Su

Correct a bug in the P function: according to 7th edition UNIX (tm), the
newline must be part of the pattern space i.e. `echo a|sed -e P' must print
a
a
and not
aa
This is consistent with gnu sed, SunOS, Ultrix (and probably others!)

show more ...


Revision tags: release/2.0, release/1.1.5.1_cvs
# 9b50d902 27-May-1994 Rodney W. Grimes <rgrimes@FreeBSD.org>

BSD 4.4 Lite Usr.bin Sources


# 2e370a5c 26-May-2009 Oleksandr Tymoshenko <gonzo@FreeBSD.org>

Merge from HEAD


# f879e8d9 25-May-2009 Brian Somers <brian@FreeBSD.org>

Implement "addr1,+N" ranges - not dissimilar to grep's -A switch.

PR: 134856
Submitted by: Jeremie Le Hen - jeremie at le-hen dot org


Revision tags: release/7.2.0_cvs, release/7.2.0, release/7.1.0_cvs, release/7.1.0, release/6.4.0_cvs, release/6.4.0, release/7.0.0_cvs, release/7.0.0
# d3e5e11c 09-Feb-2008 David Malone <dwmalone@FreeBSD.org>

WARNS fixes:
1) Add missing parens around assignment that is compared to zero.
2) Make some variables that only take non-negative values unsigned.
3) Some casts/type changes to fix other constness wa

WARNS fixes:
1) Add missing parens around assignment that is compared to zero.
2) Make some variables that only take non-negative values unsigned.
3) Some casts/type changes to fix other constness warnings.
4) Make one variable a const char *.
5) Make sure termwidth is positive, it doesn't make sense for it to be negative.

Approved by: dds

show more ...


Revision tags: release/6.3.0_cvs, release/6.3.0
# 85ae5d2f 12-Jun-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Drop the argument to the OUT macro because it can't emit
anything but the pattern space anyway. Apply style(9)
to the macro.

Tested with: md5(1)


# 26a5710c 12-Jun-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Don't forget to clear out the hold space for each subsequent file
when in -i mode so that each file gets a clean context of its own.

Add a regression test for the bug.

Tested with: regression tests


# bebfe2ad 12-Jun-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

There is a symbolic antonym for REPLACE as a flag to cspace()
and mf_fgets(): APPEND. So use it instead of a 0 constant for
clarity.

Tested with: md5(1)


# f6703c9c 21-Apr-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Change the semantics of -i (in-place editing) so that it treats
each file independently from other files. The new semantics are
desired in the most of practical cases, e.g.: delete lines 5-9
from ea

Change the semantics of -i (in-place editing) so that it treats
each file independently from other files. The new semantics are
desired in the most of practical cases, e.g.: delete lines 5-9
from each file.

Keep the previous semantics of -i under a new option, -I, which
uses a single continuous address space covering all files to edit
in-place -- they are too cool to just drop them.

Add regression tests for -i and -I.

Approved by: dds
Compared with: GNU sed
Discussed on: -hackers
MFC after: 2 weeks

show more ...


# e9a0eed4 02-Apr-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Don't forget to close the range if we branched over its end
and had no chance to match it by the 2nd address precisely.
Otherwise the unclosed range would bogusly extend to the end
of stream.

Add a

Don't forget to close the range if we branched over its end
and had no chance to match it by the 2nd address precisely.
Otherwise the unclosed range would bogusly extend to the end
of stream.

Add a basic regression test for the bug fixed. (This change
also fixes the more complex case 5.3 from `multitest.t'.)

Compared with: SUN and GNU seds
Tested by: regression tests
MFC after: 1 week

show more ...


# b1b46280 02-Apr-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Prevent foot-shooting in advance: Put the MATCH() macro's value
in parentheses. The ?: operator has a remarkably low precedence, so
expressions like (MATCH(foo) && bar) would have an unexpected mea

Prevent foot-shooting in advance: Put the MATCH() macro's value
in parentheses. The ?: operator has a remarkably low precedence, so
expressions like (MATCH(foo) && bar) would have an unexpected meaning
w/o the parentheses around MATCH().

Tested with: md5(1)

show more ...


# 6b8ef681 01-Apr-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

This trivial change should fix at least 3 similar bugs. All of
them are related to the `c' function's need to know if we are at
the actual end of the address range. (It must print the text not
earl

This trivial change should fix at least 3 similar bugs. All of
them are related to the `c' function's need to know if we are at
the actual end of the address range. (It must print the text not
earlier than the whole pattern space was deleted.) It appears the
only sed function with this requirement.

There is `lastaddr' set by applies(), which is to notify the `c'
function, but it can't always help because it's false when we are
hitting the end of file early. There is also a bug in applies()
due to which `lastaddr' isn't set to true on degenerate ranges such
as `$,$' or `N,$' if N appears the last line number.

Handling early EOF condition in applies() could look more logical,
but it would effectively revert sed to the unreasonable behaviour
rev. 1.26 of main.c fought against, as it would require lastline()
be called for each line within each address range. So it's better
to call lastline() only if needed by the `c' function.

Together with this change to sed go regression tests for the bugs
fixed (c1-c3). A basic test of `c' (c0) is also added as it helped
me to spot my own error.

Discussed with: dds
Tested by: the regression tests
MFC after: 1 week

show more ...


# c691c0ed 31-Mar-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Make the comment for cspace() match reality.


Revision tags: release/6.2.0_cvs, release/6.2.0
# 85184b8b 27-May-2006 Kirill Ponomarev <krion@FreeBSD.org>

Fix using "P" command on empty pattern space. If the "P" command is
used once on a non-empty pattern space and then again on an empty
pattern space, the second usage restores the pattern space lengt

Fix using "P" command on empty pattern space. If the "P" command is
used once on a non-empty pattern space and then again on an empty
pattern space, the second usage restores the pattern space length to
the length that it had when the first "P" was used.

PR: bin/96052
Submitted by: Andrey Zholos <aaz@althenia.net>
MFC after: 7 days

show more ...


Revision tags: release/5.5.0_cvs, release/5.5.0, release/6.1.0_cvs, release/6.1.0, release/6.0.0_cvs, release/6.0.0, release/5.4.0_cvs, release/5.4.0
# 6c97c3d1 09-Apr-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

Remove unused variables.


123456