-
Notifications
You must be signed in to change notification settings - Fork 0
/
ChangeLog-2009
3653 lines (2713 loc) · 140 KB
/
ChangeLog-2009
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
2009-11-26 Paolo Bonzini <[email protected]>
* bootstrap.conf: Add binary-io, dirname.
* configure.ac: Remove check for setmode, AC_DOSFILE.
* m4/dosfile.m4: Remove.
* src/grep.c: Adjust for dirname.h.
* src/system.h: Adjust for new gnulib modules.
2009-11-26 Paolo Bonzini <[email protected]>
* bootstrap.conf: Add gnulib modules for replacement functions and
headers.
* configure.ac: Remove macros subsumed by gnulib.
* lib/hard-locale.c: Remove guards for headers/functions provided by gnulib.
* lib/regex.c: Likewise.
* lib/savedir.c: Likewise.
* src/dfa.c: Likewise.
* src/grep.c: Likewise.
* src/mbsupport.h: Likewise.
* src/system.h: Likewise.
* src/dfa.h: Do not look at PROTOTYPES.
* m4/mbstate_t.m4: Remove.
* src/getpagesize.h: Remove.
2009-11-26 Paolo Bonzini <[email protected]>
* bootstrap.conf: Add gnulib modules and build libgreputils.a.
* configure.ac: Remove macros subsumed by gnulib.
* lib/Makefile.am: Remove files subsumed by gnulib.
* lib/alloca.c: Remove.
* lib/atexit.c: Remove.
* lib/error.c: Remove.
* lib/error.h: Remove.
* lib/fnmatch.c: Remove.
* lib/fnmatch.h: Remove.
* lib/getopt.c: Remove.
* lib/getopt.h: Remove.
* lib/getopt1.c: Remove.
* lib/gettext.h: Remove.
* lib/malloc.c: Remove.
* lib/memchr.c: Remove.
* lib/obstack.c: Remove.
* lib/obstack.h: Remove.
* lib/quotearg.c: Remove.
* lib/quotearg.h: Remove.
* lib/realloc.c: Remove.
* lib/stpcpy.c: Remove.
* lib/strtol.c: Remove.
* lib/strtoul.c: Remove.
* lib/strtoull.c: Remove.
* lib/xalloc.h: Remove.
* lib/xmalloc.c: Remove.
* lib/xstrtol.c: Remove.
* lib/xstrtol.h: Remove.
* lib/xstrtoumax.c: Remove.
* m4/error.m4: Remove.
* m4/inttypes_h.m4: Remove.
* m4/malloc.m4: Remove.
* m4/realloc.m4: Remove.
* m4/uintmax_t.m4: Remove.
* m4/ulonglong.m4: Remove.
* m4/xstrtoumax.m4: Remove.
* src/system.h: Remove strerror, sys_nerr, sys_errlist.
2009-11-26 Paolo Bonzini <[email protected]>
* bootstrap: Use gnulib's build-aux/bootstrap.
* configure.ac: Add gl_INIT and gl_EARLY.
2009-11-26 Paolo Bonzini <[email protected]>
* configure.ac: Bump AC_PREREQ to 2.59.
2009-11-26 Paolo Bonzini <[email protected]>
* lib/savedir.c: Do not use NAMLEN.
2009-11-21 Paolo Bonzini <[email protected]>
* configure.ac: Remove AC_SEP.
* m4/envsep.m4: Remove.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac: Do not generate lib/posix/Makefile.
* lib/Makefile.am: Remove SUBDIRS.
* lib/posix/Makefile.am: Remove.
* lib/posix/regex.h: Overwrite...
* lib/regex.h: ... this.
2009-11-20 Paolo Bonzini <[email protected]>
* doc/Makefile.am: Remove AUTOMAKE_OPTIONS.
* lib/posix/Makefile.am: Remove AUTOMAKE_OPTIONS.
* vms/Makefile.am: Remove AUTOMAKE_OPTIONS.
2009-11-20 Paolo Bonzini <[email protected]>
* Makefile.cvs: Remove.
2009-11-20 Paolo Bonzini <[email protected]>
* m4/largefile.m4: Remove.
* m4/lib-ld.m4: Remove.
* m4/lib-prefix.m4: Remove.
* m4/missing.m4: Remove.
* m4/nls.m4: Remove.
* m4/progtest.m4: Remove.
2009-11-20 Paolo Bonzini <[email protected]>
* bootstrap: Add autopoint invocation and fetching of .po files.
* configure.ac: Bump to GNU gettext 0.17.
* ABOUT-NLS: Remove.
* m4/gettext.m4: Remove.
* m4/iconv.m4: Remove.
* m4/lib-link.m4: Remove.
* m4/po.m4: Remove.
* po/*.po: Remove.
2009-11-20 Paolo Bonzini <[email protected]>
* autogen.sh: Rename to...
* bootstrap: ... this.
2009-11-20 Paolo Bonzini <[email protected]>
* bootstrap/*: Remove.
* configure.ac: Do not create bootstrap/Makefile.
* Makefile.am: Do not recurse into bootstrap, distribute new files.
* Makefile.boot: Move from bootstrap/Makefile.try.
* README-boot: Move from bootstrap/README.
2009-11-20 Paolo Bonzini <[email protected]>
* lib/Makefile.am: Distribute gettext.h.
* lib/closeout.c: Use it.
* lib/gettext.h: New.
* lib/quotearg.c: Use it.
* lib/xmalloc.c: Use it.
* src/dfa.c: Use it.
* src/system.h: Use it.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac.in: Rename...
* configure.ac: ... to this. Remove ALL_LINGUAS definition.
* autogen.sh: Generate po/LINGUAS instead of configure.ac.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac.in: Remove pointless (?) stamp-h rule.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac.in: Remove m4/Makefile creation.
* Makefile.am: Remove m4 subdirectory.
* m4/Makefile.am: Remove.
* m4/codeset.m4: Remove.
* m4/glibc.m4: Remove.
* m4/glibc21.m4: Remove.
* m4/header.m4: Remove.
* m4/install.m4: Remove.
* m4/isc-posix.m4: Remove.
* m4/lcmessage.m4: Remove.
* m4/sanity.m4: Remove.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac.in (AM_GNU_GETTEXT_VERSION): Bump to 0.17.
* Makefile.am (EXTRA_DIST): Add build-aux/config.rpath.
* intl/*: Remove.
* m4/gettext.m4: Upgrade to gettext-0.17.
* m4/iconv.m4: Upgrade to gettext-0.17.
* m4/lib-ld.m4: New file, from gettext-0.17.
* m4/lib-link.m4: New file, from gettext-0.17.
* m4/lib-prefix.m4: New file, from gettext-0.17.
* m4/nls.m4: New file, from gettext-0.17.
* m4/po.m4: New file, from gettext-0.17.
* m4/progtest.m4: Upgrade to gettext-0.17.
* m4/Makefile.am (EXTRA_DIST): Add the new files.
* po/Makefile.in.in: Upgrade to gettext-0.17.
* po/Makevars: New.
* po/cat-id-tbl.c: New.
* src/Makefile.am: Replace @INTLLIBS@ with @LIBINTL@.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac.in: Test for limits.h, locale.h, stddef.h, mempcpy
and setlocale, though already done implicitly via AM_GNU_GETTEXT.
2009-11-20 Paolo Bonzini <[email protected]>
* bootstrap/Makefile.try: Adjust.
* lib/savedir.c: Avoid using stpcpy, so that bootstrapping does not
need it.
2009-11-20 Paolo Bonzini <[email protected]>
* configure.ac: Slightly modernize.
* Makefile.am: Modernize, use dependencies.
* Makefile.am: Modernize, use dependencies.
* lib/Makefile.am: Remove ansi2knr.
* src/Makefile.am: Remove ansi2knr.
* .gitignore: Add INSTALL
* build-aux/.gitignore: New.
2009-11-20 Paolo Bonzini <[email protected]>
* autogen.sh: Remove what is useless with git.
2009-02-10 Tony Abou-Assaleh <[email protected]>
* po/*.po: update from the Translation Project
* configure.ac.in: update version to 2.6-cvs
2009-02-02 Karl Berry <[email protected]>
* configure.ac.in (pcre): set CPPFLAGS, not CFLAGS.
2009-02-01 Tony Abou-Assaleh <[email protected]>
* po/*.po: update from the Translation Project
* po/Makefile.in.in: Remove deleted file ChangeLog from DISTFILES
* configure.ac.in: Replace obsolete macro AC_OUTPUT with modern equivalent
2009-02-01 Karl Berry <[email protected]>
* missing: re-add (from gnulib), since it's missing.
* src/grep.c (usage): consistent punctuation.
2009-01-31 Tony Abou-Assaleh <[email protected]>
* m4/*.m4: quote underquoted definitions
* m4/codeset.m4: serial AM1 -> serial 1
* m4/iconv.m4: serial AM2 -> serial 2
* m4/header.m4: m4_regexp -> m4_bregexp, m4_patsubst -> m4_bpatsubst
2009-01-29 Karl Berry <[email protected]>
* src/grep.c (usage): mention gnu.org/s/grep and gnu.org/gethelp.
Update and/or add copyright notices:
* ABOUT-NLS
* AUTHORS
* ChangeLog
* Makefile.am
* NEWS
* README
* README-alpha
* README.DOS
* THANKS
* autogen.sh
* configure.ac.in
* bootstrap/Makefile.am
* bootstrap/Makefile.try
* bootstrap/README
* doc/Makefile.am
* doc/grep.texi
* lib/Makefile.am
* m4/Makefile.am
* po/POTFILES.in
* src/Makefile.am
* src/dfa.h
* src/dosbuf.c
* src/grep.h
* src/kwset.c
* src/kwset.h
* src/mbsupport.h
* src/search.c
* src/system.h
* src/vms_fab.c
* src/vms_fab.h
* tests/Makefile.am
* tests/backref.sh
* tests/bre.awk
* tests/bre.sh
* tests/empty.sh
* tests/ere.awk
* tests/ere.sh
* tests/file.sh
* tests/fmbtest.sh
* tests/foad1.sh
* tests/khadafy.sh
* tests/options.sh
* tests/pcre.sh
* tests/spencer1.awk
* tests/spencer1.sh
* tests/spencer2.sh
* tests/status.sh
* tests/tests
* tests/warning.sh
* tests/yesno.sh
* vms/Makefile.am
* vms/config_vms.h
* po/ChangeLog: remove this file, just a bit of ancient cruft.
2009-01-25 Tony Abou-Assaleh <[email protected]>
* README: updated "KNOWN BUGS" section
2009-01-24 Bruno Haible <[email protected]>
* lib/posix/regex.h (__restrict, __restrict_arr): Remove macros.
(_Restrict_, _Restrict_arr_): New macros. From gnulib/lib/regex.h.
(regcomp, regexec): Update declarations to use them.
* lib/savedir.c (isdir): New declaration.
* src/dfa.c (update_mb_len_index): Change argument type to
'char const *'.
(match_mb_charset): Cast argument to strncpy.
(dfaexec): Add pointer cast.
* src/grep.c (parse_grep_colors): Add braces for disambiguation.
* src/kwset.c: Include xalloc.h instead of declaring xmalloc manually.
2009-01-20 Tony Abou-Assaleh <[email protected]>
* tests/foad1.sh: disable tests that fail under cs_CZ.UTF-8.
* tests/fmbtest.sh: likewise
* README: added "KNOWN BUGS" section
* src/grep.c: updated copyright year
2008-12-12 Karl Berry <[email protected]>
* doc/grep.texi (Exit Status, grep Programs): move these
nodes to under Invoking.
* doc/grep.texi: remove all remaining node pointers;
downcase cindex entries.
2008-12-11 Karl Berry <[email protected]>
* doc/grep.texi (Copying): update url's.
(GNU General Public License): remove node.
(GNU Free Documentation License): @include fdl.texi instead.
(@copying): update to v1.3 or later.
* doc/fdl.texi: new file, copied from
http://www.gnu.org/licenses/fdl.texi.
* doc/Makefile.am (grep_TEXINFOS): new variable to get fdl.texi.
Also add usual GPL license statement.
* doc/grep.texi (Index): Merge in Concept Index node,
to have only one index. Arrange @syncodeindex's accordingly.
2008-12-10 Karl Berry <[email protected]>
* doc/grep.texi (@copying): use @copying; move @contents to
beginning; rearrange other frontmatter in the conventional ways.
2008-06-15 Tony Abou-Assaleh <[email protected]>
* src/ansi2knr.[1c]: Remove generated files (installed by
automake). Thanks to Emanuele Giaquinta for this.
2008-02-14 Tony Abou-Assaleh <[email protected]>
* src/grep.c: Factor out copyright year in --version. Thanks to
Karl Berry for this.
* src/grep.c: Update copyright years
* po/POTFILES.in: +src/system.h +lib/closeout.c +lib/regex.c
+lib/xmalloc.c -lib/getopt1.c
2008-02-09 Tony Abou-Assaleh <[email protected]>
* src/dfa.c: Replace a MALLOC and for loop with a CALLOC. Thanks to
Johan Walles for this. Patch #6288
* README-alpha: more info about CVS code
* README: pointer to README-alpha
* src/grep.c: Update grep copyright year
2008-02-08 Reuben Thomas <[email protected]> (tiny change)
* .cvsignore: add configure.ac
* src/.cvsignore: add .deps
2008-02-06 Tony Abou-Assaleh <[email protected]>
* tests/foad1.sh: Comment out cases that are known to fail. These
should be uncommented after the 2.5.4 release.
* tests/yesno.sh: Likewise.
* doc/grep.1: Update description of -e PATTERN; from Benno Schulenberg
* doc/grep.texi: Likewise.
2007-11-19 Tony Abou-Assaleh <[email protected]>
* m4/Makefile.am: Remove reference strerror_r.m4
2007-11-16 Tony Abou-Assaleh <[email protected]>
* po/sk.po: updated from the translation project
2007-11-03 Tony Abou-Assaleh <[email protected]>
* po/*.po: get latest translations
* po/no.po: removed
* po/ky.po: added
* po/sk.po: added
2007-10-10 Tony Abou-Assaleh <[email protected]>
* configure.ac.in: update version to 2.6-dev
* src/grep.c: update --version message
2007-10-07 Tony Abou-Assaleh <[email protected]>
* src/grep.c: When -h and -H are combined, use the last specified,
Bug #15620, Patch #4866
* tests/foad1.sh: add tests for -h and -H
* ChangeLog: Add a copyright notice (years taken from commit logs),
add a license notice (taken from gnulib ChangeLog)
* TODO: update the link to a list of other grep implementations
2007-06-29 Bernhard Rosenkraenzer <[email protected]>
* all files: GPLv3
* configure.ac.in: Change version number
2006-11-25 Bernhard Rosenkraenzer <[email protected]>
* configure.ac.in: Update version number for post-2.5.2 development
2006-11-25 Bernhard Rosenkraenzer <[email protected]>
* configure.ac.in, grep.spec: Update version number
* Makefile.cvs: Update to work with current autoconf scripts
* po/Makefile.in.in: Adjust to work with automake 1.1x
2006-08-19 Bernhard Rosenkraenzer <[email protected]>
* po/*: Sync with translation project
* doc/*: Assorted documentation updates, Patch #4610
* autogen.sh, configure.in, configure.ac.in: Autogenerate
ALL_LINGUAS variable
* m4/strerror_r.m4, configure.ac.in: Fix detection of strerror_r
* lib/error.c: Remove bogus warning
* lib/savedir.c, lib/savedir.h, src/grep.c, doc/*:
Add --exclude-dir option (patch #5051)
2005-11-18 Charles Levert <[email protected]>
* tests/foad1.sh: Use ": ${VERBOSE=}" so that the caller can
set it without modifying the script; the usual caller (Makefile)
still leaves it untouched (usually unset, so it's off by default).
Modify "-m1 -A99 '^...$'" tests that failed so that their
expectation now corresponds to the output currently produced
by grep. Those tests used to expect that two selected (or
selectable) lines be output, even with -m1. Nothing was
modified with other similar tests that output _context_ lines
after one selected line has been output with -m1; they used to
and still succeed. Although tests/yesno.sh now provides a more
comprehensive framework for testing -m/-C feature interaction,
it doesn't exercise mixing them with anchors so the whole
relevant tests/foad1.sh test group is kept, notably to check
that grep doesn't crash when it is run.
2005-11-17 Charles Levert <[email protected]>
On 2005-06-21, many changes were made that affected --color,
--only-matching, and --invert-match. Some of them introduced a
misunderstanding between the concepts of matched/non-matched and
selected/rejected lines. Furthermore, a few bugs with -v sneaked
in stemming from this. This set of changes aims to rectify most
of this situation. Some GREP_COLORS capabilities are also added
as a result of the clarification. (Further issues with -v/-o/-C
feature interaction still remain to be sorted out.)
* src/grep.c: Rename/add global variables, macros, and capabilities:
SEP_CHAR_MATCH --> SEP_CHAR_SELECTED
SEP_CHAR_CONTEXT --> SEP_CHAR_REJECTED
SEP_STR_CHUNK --> SEP_STR_GROUP
grep_color --> selected_match_color + context_match_color
mlines_color --> selected_line_color
context_color --> context_line_color
"ml" --> "sl"
"mt" --> "mt" = "ms" + "mc"
--> "rv" (reverse "sl"/"cx" when -v)
* src/grep.c (color_cap_mt_fct, color_cap_rv_fct): New functions.
* src/grep.c (print_line_tail): Renamed color argument to line_color.
* src/grep.c (print_line_middle, prline): Revert part of the logic to
a pre-2005-06-21 one so that lines with matches have their matched
parts properly handled again ("m?" colors or --only-matching),
whether or not -v is specified. Whole line colors ("sl", "cx")
follow a selected / rejected(context) logic, as opposed to a
matched / non-matched one (unless "rv"). Matched text colors ("ms",
"mc") always follow a selected / rejected(context) logic,
regardless of "rv", because only matched lines use them anyway.
pr_line_middle() now takes additional line_color and match_color
arguments computed by prline() prior to calling that function.
The old logic was a buggy hybrid matched / rejected(context) one.
* src/grep.c (prpending, prtext, grepfile): Renamed macro invocations.
* src/grep.c (parse_grep_colors): Update top comment.
* src/grep.c (main): GREP_COLOR (singular) now sets both
selected_match_color and context_match_color.
2005-11-16 Charles Levert <[email protected]>
* src/search.c (Pcompile): Clarify message for the -P option
not being supported so that users don't assume it's a run-time
problem, but know that it's a compile-time configuration choice.
Based on an idea by: Benno Schulenberg <[email protected]>.
2005-11-13 Charles Levert <[email protected]>
* tests/yesno.sh: New file. Test feature interaction
of -C, -v, -o, and -m. This reveals bugs, including some I
introduced on 2005-06-21, but also others.
* tests/Makefile.am (TESTS): Add yesno.sh.
* tests/Makefile.am (CLEANFILES): Add cspatfile and csinput, as
created by fmbtest.sh. Add yesno.txt, as created by yesno.sh.
2005-11-11 Charles Levert <[email protected]>
* configure.in (ALL_LINGUAS): Add languages that were missing
from this variable (bg, ca, da, nb, tr), but that GNU grep supports
with a po/xx.po file. Reported by Tony Abou-Assaleh <[email protected]>.
* src/search.c (Pcompile): Abort in error if -P and multiple patterns
are specified, with an error message explaining the situation.
Fixing this won't be simple; the '\n' characters separating the
patterns cannot just be replaced by '|' to create an alternation as
back-references are assumed to be local to each individual pattern.
* src/grep.c (parse_grep_colors, main): Replace all uses of
fprintf(stderr, _("%s: foo\n"), program_name, ...) with
error(0, 0, _("foo"), ...) for uniformization and simplification
of warning messages that will be up for localization. (My bad.)
2005-11-10 Charles Levert <[email protected]>
The introduction of the --only-matching and --color GNU extensions
to grep added the requirement that each execute() implementation
not only be able to identify matching lines as a whole, but also
individual "exact" matches within a line known to be matching,
from leftmost to rightmost match, when the output from matching
lines is actually produced. The interface and implementations
of execute() were not up to it. This set of changes aims to
rectify that situation. Previously failing tests relative to
left anchors (^ and \<) and -w should now pass. This fixes
<http://savannah.gnu.org/bugs/?func=detailitem&item_id=11579>,
<http://savannah.gnu.org/patch/?func=detailitem&item_id=1834>,
<http://savannah.gnu.org/bugs/?func=detailitem&item_id=8243>,
and possibly part of other, bigger, pending patches. The problem
was also compounded by the POSIX requirement to support a pattern
list instead of just an individual pattern (for -G and -E as well).
* tests/foad1.sh: Test for increasing/decreasing-length word
matches, given pattern order, and leftmost/longest match.
* tests/fmbtest.sh: Modify test #6 according to new expectations.
Better document what tests #6 and #7 are actually for. Eliminate
test #5 in favor of bringing tests #6 and #7 within the F G E loop.
* src/grep.h (EXECUTE_ARGS): Change last argument from "int exact"
to "char const *start_ptr". Testing for "start_ptr" being non-NULL
retains the same semantics as testing for "exact" being non-zero.
* src/grep.c (print_line_middle): Call execute() with whole
buffer to work on, but using current position as start_ptr.
* src/grep.c (prpending, grepbuf): Call execute() with NULL
as start_ptr.
* src/search.c (EGexecute, Fexecute, Pexecute): When start_ptr is
non-NULL, return first match from it as an offset relative to buf.
* src/search.c (EGexecute): Consider all patterns if many and,
for an exact match, return the best one (leftmost, then longest).
Don't explore worst solutions, of course (branch and bound).
2005-11-10 Charles Levert <[email protected]>
* src/grep.c (main): Fix a subtle memory allocation bug introduced
with the mb_icase_keys() function, which can call xrealloc() or
free() on keys, by making sure keys is always dynamically allocated.
2005-11-09 Charles Levert <[email protected]>
* doc/grep.1, doc/grep.texi: Advise users to test for
"exit_status > 1" instead of "exit_status == 2" in order to
detect errors, for portability with other POSIX-compliant
implementations.
2005-11-09 Charles Levert <[email protected]>
The following set of changes aims to make "egrep" and "fgrep"
minimal executable programs for legacy applications, instead of
shell scripts. This "fgrep" is much smaller than "grep".
This set of changes appears more daunting than it really is.
* src/egrep.c, src/fgrep.c, src/esearch.c, src/fsearch.c: New files
that #define either EGREP_PROGRAM or FGREP_PROGRAM and #include
the corresponding generic (i.e., non e or f specific) *.c file.
* src/grepmat.c: Remove whole file.
* src/Makefile.am: Remove no-dependencies from AUTOMAKE_OPTIONS.
Add definitions to make "egrep" and "fgrep" specific standalone
executable programs that only use the source files they need.
Remove rules for "egrep" and "fgrep" shell scripts.
* src/grep.h: #define GREP_PROGRAM if both EGREP_PROGRAM and
FGREP_PROGRAM are #undef. Only declare matchers[] in this case
along with the compile_fp_t and execute_fp_t function pointers
typedefs, otherwise declare prototypes for straight compile()
and execute() functions for the specialized "egrep" and "fgrep"
programs. Remove the extern declaration for matcher.
Define COMPILE_RET, COMPILE_ARGS, EXECUTE_RET, EXECUTE_ARGS,
COMPILE_FCT, and EXECUTE_FCT helper preprocessor macros.
* src/grep.c (short_options, long_options, usage, main): Only
support -G, -E, -F, -P, and -X for GREP_PROGRAM, but not for
EGREP_PROGRAM or FGREP_PROGRAM. Customize usage messages.
* src/grep.c (set_limits): New function with unchanged code,
called from main(), because it shouldn't be in install_matcher()
since it was already matcher-independent.
* src/grep.c (matcher): Add as static, only for GREP_PROGRAM.
* src/grep.c (setmatcher, install_matcher): Only for GREP_PROGRAM.
* src/grep.c (main): Remove any tweaking and dependence on argv[0].
* src/grep.c (print_line_middle, prpending, grepbuf, main): Call
compile() and execute() directly, not through a function
pointer dereferencing notation, so that it works with both
straight functions (in EGREP_PROGRAM and FGREP_PROGRAM) and
function pointers (in GREP_PROGRAM).
* src/search.c (<regex.h>, "dfa.h", dfa, pattern0, patterns,
pcount, dfaerror, kwset_exact_matches, kwsmusts): Only
include/declare/define if not FGREP_PROGRAM.
* src/search.c: Remove function prototypes for all functions
that are not used before their definition, since this is just
a hassle now with their varying names and conditional definition.
* src/search.c (GEAcompile): Rename from Ecompile(). Add new
syntax_bits argument/variable. Use as compile() for EGREP_PROGRAM.
Put in the needed RE_ICASE fix, albeit commented-out for now.
Make sure to free() modified word/line pattern after use, if any.
* src/search.c (Gcompile): Merge with GEAcompile() then remove.
* src/search.c (Gcompile, Acompile, Ecompile): New small functions
that call GEAcompile(), now that matcher is not an extern variable.
* src/search.c (GEAcompile, Gcompile, Acompile, Ecompile,
Fcompile, Pcompile, EGexecute, Fexecute, Pexecute, matchers):
Only define when needed according to *GREP_PROGRAM, and rename
to just compile() and execute() when appropriate.
* grep/bootstrap/Makefile.try: Similar changes.
2005-11-08 Charles Levert <[email protected]>
* README.DOS, TODO, grep.spec, doc/grep.1, doc/grep.texi,
src/grep.h, po/da.po, po/nb.po, po/no.po, po/sv.po:
Replace all capitalized "Grep" by a lowercase "grep", except
in citations. Reported by Benno Schulenberg <[email protected]>
from the <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=190551>
entry in the Debian bug tracker.
* doc/grep.1, doc/grep.texi: Explain that the "egrep" and "fgrep"
commands are deprecated and provided for historical applications.
Replace some "egrep" uses by "grep -E" to promote the newer usage.
Typeset "zgrep" as a command. Fix some spacing and punctuation bugs.
2005-11-08 Julian Foad <[email protected]>
* doc/grep.texi: Rewrite a poorly written usage example about
back-references, and tweak another. New text by Benno Schulenberg.
2005-11-04 Charles Levert <[email protected]>
* src/grep.c (mb_icase_keys): New function to properly lowercase
keys if match_icase. The problem was that some multi-octet
characters can get longer or shorter upon this conversion, so that
it cannot just naively be done in place on the same memory buffer.
* src/grep.c (main): Call mb_icase_keys (and remove in-line code).
* tests/foad1.sh: Duplicate three "-o -b" tests for the "-F"
mode because it relies on a different code path that deserves
the same kind of testing.
2005-09-27 Stepan Kasal <[email protected]>
* doc/grep.1: Fix a typo.
2005-08-24 Charles Levert <[email protected]>
* src/grep.c (print_line_middle): In case of an empty match,
make minimal progress and continue instead of aborting process
of the remainder of the line, in case there's still an upcoming
non-empty match.
* tests/foad1.sh: Add two tests for this.
* doc/grep.texi, doc/grep.1: Document this behavior, since
--only-matching and --color are GNU extensions which are
otherwise unspecified by POSIX or other standards.
2005-07-26 Charles Levert <[email protected]>
* tests/pcre.sh: New file. Add test 1.
* tests/Makefile.am: Add pcre.sh to TESTS.
2005-07-07 Charles Levert <[email protected]>
* src/grep.c: Remove all xm capability code.
2005-07-05 Charles Levert <[email protected]>
* doc/grep.texi: Add missing green color in GREP_COLORS description.
* doc/grep.1: Fix typo and reorganize GREP_COLORS documentation.
* src/kwset.c (DEPTH_SIZE): New macro to anticipate
architectures/compilers where CHAR_BIT is not 8 (we assume it
won't be less than 4, which would be non-standard and unlikely).
Checked to hold for CHAR_BIT up to 1023 (and maybe more)!
* src/kwset.c (kwsincr): Use DEPTH_SIZE in two array declarations.
* src/kwset.c (kwsincr): When a second obstack_alloc() call fails,
free what the first one successfully allocated by popping it
off the top of the obstack, before returning in error, just
to keep things clean.
* src/kwset.c (kwsprep): Verify return value of obstack_alloc()
and return a memory exhausted error if so. This function had
a prototype to return such errors, but never did.
2005-07-04 Charles Levert <[email protected]>
* src/kwset.c: Readability changes.
Replace uses of 0 for pointer values by NULL.
Generalize use of existing U() macro to whole file.
* src/kwset.c (kwsprep): Use memset() and memcpy() when appropriate.
* src/kwset.c (kwsprep): Move three variable declarations to
the single {}-block where they are used.
* src/kwset.c (kwsprep): Optimize search for mind2 value by
starting from the end of the target[] array.
2005-06-22 Charles Levert <[email protected]>
* grep/autogen.sh, grep/src/Makefile.am, grep/tests/backref.sh,
grep/tests/bre.sh, grep/tests/empty.sh, grep/tests/ere.sh,
grep/tests/file.sh, grep/tests/fmbtest.sh, grep/tests/foad1.sh,
grep/tests/khadafy.sh, grep/tests/options.sh,
grep/tests/spencer1.sh, grep/tests/spencer2.sh,
grep/tests/status.sh, grep/tests/warning.sh: As per autoconf's
"Portable Shell Programming" guidelines, replace all instances
of "#!/bin/sh" by "#! /bin/sh" (notice the space).
2005-06-21 Charles Levert <[email protected]>
* src/grep.c (nlscan): Make this function more robust by removing
the undocumented assumption that its "lim" argument points
right after a line boundary. This will be used later to fix
--byte-offset's broken behavior. Patch #3769.
* src/grep.c (main): Add a test to check if -o/--only-matching
and context lines are both specified and if so, set both context
specifications (before and after) to zero then print an explicit
warning to stderr explaining what was done and why (as opposed
to drastically aborting the process in error). Patch #3768.
Other code needs this zero setting to work correctly without
having to repeatedly test for this conflictual condition.
* tests/foad1.sh: Add tests combining -o, -n/-b/-H, and -i,
since there are separate code paths for -i. Add tests combining
-o, -n/-b/-H, and -3, since any context line specification
should be ignored when combined with -o.
* src/grep.c (print_line_head): New function, culled off the
top content of prline(). Adds a guard against "lastnl" having
already reached "lim", which can happen when if the function
is called more than once per line.
* src/grep.c (prline): Now calls print_line_head(), not only at
the beginning to replace the moved code when -o is not
specified, but also for each match when -o is specified (two
code paths with this). Patch #3770, more or less. This makes
all tests combining -o and -n/-b/-H pass, which they didn't
before. Fixes bug #12727.
* src/grep.c (SEP_CHAR_MATCH, SEP_CHAR_CONTEXT, SEP_STR_CHUNK):
New macros for ':', '-', and "--". Used throughout the file.
Will be used even more in upcoming updates, so good to have now.
* src/grep.c: The new GREP_COLORS (plural) framework, only
partially used at this point to make for a simpler initial
patch in CVS. A subset of patch #3644 on Savannah.
* src/grep.c (color_cap_ne_fct, color_cap_xm_fct, print_filename,
print_sep, parse_grep_colors): New functions.
* src/grep.c (prtext, grepfile, main): Existing functions modified
to use the new framework.
* doc/grep.texi, doc/grep.1: Document GREP_COLORS.
* src/grep.c: The new -T/--initial-tab framework, only
partially used at this point to make for a simpler initial
patch in CVS. A subset of patch #3644 on Savannah.
The option name/calling convention is the same as for GNU diff.
* doc/grep.texi, doc/grep.1: Document -T/--initial-tab.
* src/grep.c (print_offset): Renamed print_offset_sep() to better
represent its new functionality; new calling convention.
* src/grep.c (print_offset, print_line_head): Use and implement
missing parts of the GREP_COLORS and -T/--initial-tab frameworks.
* src/grep.c (print_line_middle, print_line_tail): New functions,
unused for now, intended to allow a simplifying rewrite of
prline(). Adding them first will make for cleaner CVS patches.
* src/grep.c (prline): Simplifying rewrite using
print_line_middle() and print_line_tail(). No longer attempts
to find matches to colorize in context lines, thus avoiding
costly calls to (*execute)(), since we know by then that they
can't contain any by definition. There are no longer four
different code paths whether -o and -i are each specified
or not; they have been unified into one, which should help
avoid bugs similar to previous ones due to not updating all
code paths in a synchronized fashion. The -i code has been
explicitly marked since it doesn't belong there and should
be removed as soon as other -i code elsewhere is fixed.
The remaining GREP_COLORS functionality is implemented.
Savannah patch #3771 and patch #3644, heavily reworked.
* src/grep.c (color_cap_ne_fct, color_cap_xm_fct,
print_line_middle, print_line_tail): Make these four functions
static.
2005-06-20 Charles Levert <[email protected]>
* src/grep.c: Extensively document the SGR/EL-to-Right issue.
* src/grep.c: Explain the context and logic for choosing default
--color screen attributes (SGR parameters).
2005-06-15 Charles Levert <[email protected]>
* tests/foad1.sh: Since this script is run by /bin/sh, it
must work under posix mode. That means not using assignment
statements right before a function call (LC_ALL=... grep_test,
in this case), because it won't do the expected thing.
2005-06-14 Charles Levert <[email protected]>
Fix bug #11022 (Line wrapping causes GREP_COLOR background
color to "smear") by outputting a "clear to end of line"
control sequence after each SGR (Select Graphic Rendition)
control sequence (START and END). This also avoid similar
problems with HT (tab) characters.
* src/grep.c (SGR_START, SGR_END, PR_SGR_FMT, PR_SGR_FMT_IF,
PR_SGR_START, PR_SGR_END, PR_SGR_START_IF, PR_SGR_END_IF):
New macros.
* src/grep.c (prline): Use the new macros.
* tests/fmbtest.sh, tests/foad1.sh: Adjust the regression tests
to expect the new control sequences.
2005-05-06 Charles Levert <[email protected]>
* TODO: Add a few more projects and derived versions to check out.
2005-05-05 Charles Levert <[email protected]>
* README-alpha: Document grep-commit mailing list.
* TODO: Add various stuff culled from the mailing list.
2005-05-02 Charles Levert <[email protected]>
* 78 files: Update FSF's civic address, zip code,
and citizen relocation code.
2005-04-29 Charles Levert <[email protected]>
* tests/foad1.sh: Add -b and tricky UTF-8 tests.
Display LC_ALL when its value is special. Patch #3962.
* ABOUT-NLS: Sync with CVS revision 1.9
of 2005-04-13T11:21:55Z from GNU gettext
on ":pserver:[email protected]:/cvs/gettext",
file "gettext/gettext-runtime/ABOUT-NLS".
2005-04-29 Julian Foad <[email protected]>
* Makefile.am: Remove reference to long-gone files PATCHES.AC and
PATCHES.AM. Thanks to Tony Abou-Assaleh for this. Patch #3961.
2005-04-29 Charles Levert <[email protected]>
* src/grep.c: Fix typo in prline()'s --only-matching --ignore-case
code path; this fixes bug #9768 and passes one more test
in tests/foad1.sh. This whole code path should be removed in
the future, when other --ignore-case issues are dealt with.
2005-04-28 Julian Foad <[email protected]>
* tests/foad1.sh: Remove Bash-specific syntax.
* src/dfa.c: Fix a DFA bug whereby a bracket "[" was matched by the
pattern "[[:alpha:]]" in UTF-8 locales. Patch #3800, by Tim Waugh.
* tests/foad1.sh: Add a regression test for that.
2005-04-27 Julian Foad <[email protected]>
Fix a bug reported by Elliott Hughes in patch #1834 whereby "grep -Fw"
would miss matches after a non-word occurrence of the pattern. Fix by
Gordon Lack; tests based on reproduction recipes by Gordon Lack.
* src/search.c (Fexecute): Fix the "match_words" case.
* tests/foad1.sh: Modify the test framework so that the "PATTERN"
argument is optional. Add a regression test and a test for
a similar case that other proposed patches have got wrong.
Add more tests, some initially failing.
* tests/foad1.sh: Add tests for "--color", most initially failing.
* tests/fmbtest.sh: New file of tests for "grep -i" with multi-byte
chars, by Jakub Jelinek, from patch #3808: Red Hat's "tests" patch.
Initially, test #4 fails (in all three modes).
* tests/Makefile.am: Include the new tests file "fmbtest.sh".
2005-04-12 Julian Foad <[email protected]>
* tests/bre.tests: Enable a regression test for bug #9519.
* src/grep.c: Fix a seg-fault in "-o -i": patch #1939.
* tests/foad1.sh: New tests for "-o", initially all failing.
* tests/Makefile.am: Include the new tests file "foad1.sh".
* tests/spencer2.sh: Be consistent with "spencer1.sh" in the
naming of associated files.
* src/grep.c: Fix off-by-one error in prpending().
Patch #3840 by Claudio Fontana.
* tests/foad1.sh: Add tests by Pavol Gono for patch #3840.
Some of them still fail, but no longer seg-fault due to that bug.
2005-04-11 Julian Foad <[email protected]>
* doc/grep.texi, doc/grep.1: Document USG grep -s too.
Based on a patch by Paul Eggert; suggested by Keith Marshall.
* src/dfa.c (lex): Fix bug #9519: "echo do^re | grep do^re" was
failing to find a match.
2005-03-09 Stepan Kasal <[email protected]>
* src/search.c (EGexecute, Fexecute): Use xmalloc, not malloc.
(EGexecute): Handle the failure in one place, goto there.
2005-02-26 Stepan Kasal <[email protected]>
* src/grep.c (get_nondigit_option): Don't give up too early.
* src/search.c (Pexecute): Add a comment explaining that this
situation should not happen.
2005-02-22 Claudio Fontana <[email protected]> (tiny change)
* src/search.c (Pexecute): Consider eof case when delimiting
matching line. Fixes bug #4531.
2005-02-23 Julian Foad <[email protected]>
* po/ko.po: Fix email address.
* README-alpha: Fix email addresses and clarify the notes.
* tests/backref.sh: Fix trivial typos.
2005-02-08 Bruno Haible <[email protected]> (tiny change)
* src/kwset.h (kwsincr, kwsprep): Change return type to 'const char *'.
* src/kwset.c (kwsincr, kwsprep): Likewise.
2005-02-08 Arnold D. Robbins <[email protected]>
Stepan Kasal <[email protected]>
* src/mbsupport.h: Don't say the file is part of GAWK.
Make wording in explanatory comment more generic.
2005-02-07 Stepan Kasal <[email protected]>
* src/grep.c: Document that -X is undocumented.
2005-01-16 Bruno Haible <[email protected]> (tiny change)
Stepan Kasal <[email protected]>
* configure.in: Add tests for iswctype, mbrlen, wcrtomb, wcscoll;
use AC_FUNC_MBRTOWC to check for mbrtowc and mbstate_t; move
AC_MBSTATE_T below it.
* src/grep.c: Include mbsupport.h to define MBS_SUPPORT uniformly.
* src/mbsupport.h: Don't test for HAVE_WCTYPE_T.
2005-01-13 Arnold D. Robbins <[email protected]>
* src/dfa.c (dfaparse): Use LC_COLLATE whenever it is defined;
ENABLE_NLS has nothing to do with this.
2005-01-07 Stepan Kasal <[email protected]>
* tests/status.sh: Added two tests--option '-s' should have no
influence on the exit status.
2004-12-16 Stepan Kasal <[email protected]>