Hi Sven,

> but what about this diff,

1) Please use diff -up.
2) It doesn't apply to my tree.

If i understand your intention correctly, that is, replacing
the "} else {" by just "}" and doing the content of the else 
clause unconditionally, that's plain wrong.  It makes sed
miss one out of two replacements:

 $ echo abcdef | ./obj/sed 's/./x/g'
xbxdxf

> just adding the new when rm_so is 0

Parse error.

> (how to run the regression test ?):

cd /usr/src/usr.bin/sed/
make cleandir
make obj
make depend
make
sudo make install
cd /usr/src/regress/usr.bin/sed/
make cleandir
make obj
make regress

It fails all over the place.

Yours,
  Ingo

> Index: process.c
> ===================================================================
> RCS file: /cvs/src/usr.bin/sed/process.c,v
> retrieving revision 1.15
> diff -r1.15 process.c
> 89a90
> >
> 250d250
> <
> 353,362d352
> <                       } else {
> <                               if (match[0].rm_so == 0)
> <                                       cspace(&SS, s, match[0].rm_so + 1,
> <                                           APPEND);
> <                               else
> <                                       cspace(&SS, s + match[0].rm_so, 1,
> <                                           APPEND);
> <                               s += match[0].rm_so + 1;
> <                               slen -= match[0].rm_so + 1;
> <                               lastempty = 1;
> 363a354,362
> >                       if (match[0].rm_so == 0)
> >                               cspace(&SS, s, match[0].rm_so + 1,
> >                                       APPEND);
> >                       else
> >                               cspace(&SS, s + match[0].rm_so, 1,
> >                                       APPEND);
> >                       s += match[0].rm_so + 1;
> >                       slen -= match[0].rm_so + 1;
> >                       lastempty = 1;

Reply via email to