summaryrefslogtreecommitdiff
path: root/src/diff.c
Commit message (Collapse)AuthorAgeFilesLines
* New option --no-dereference.Bruno Haible2012-01-081-4/+70
| | | | | | | | | | | | | | | * src/diff.h (no_dereference_symlinks): New variable. * src/diff.c: Include xreadlink.h. (longopts): Add --no-dereference option. (main): Accept --no-dereference option. (option_help_msgid): Mention the --no-dereference option. (compare_files): If no_dereference_symlinks is true, use lstat() instead of stat(). Compare symbolic links by comparing their values. * bootstrap.conf (gnulib_modules): Add lstat, stat, xreadlink. * doc/diffutils.texi (Comparing Directories, diff Options): Mention the --no-dereference option. * tests/no-dereference: New file. * tests/Makefile.am (TESTS): Add it.
* maint: update all copyright year number rangesJim Meyering2012-01-011-1/+1
| | | | Run "make update-copyright".
* portability: use SET_BINARY rather than xfreopen (NULL, ...Claudio Bley2011-10-041-3/+3
| | | | | | | * src/diff.c: Include binary-io.h, not xfreopen.h. (main): Use SET_BINARY (...) rather than xfreopen (NULL, X, ...), because the latter doesn't work on MinGW and crashes using MSVC. * src/cmp.c (main): Likewise.
* diff, sdiff: new option --ignore-trailing-space (-Z)Roland McGrath2011-08-141-3/+10
| | | | | | | | | | | | | | Derived from Roland McGrath's patch (dated June 2004!) in: http://lists.gnu.org/archive/html/bug-gnu-utils/2004-07/msg00000.html * NEWS: * doc/diffutils.texi (White Space, Blank Lines) (sdiff Option Summary, diff Options, sdiff Options): Document -Z. * src/diff.h (IGNORE_TRAILING_SPACE) (IGNORE_TAB_EXPANSION_AND_TRAILING_SPACE): New constants, for -Z. * src/diff.c (shortopts, longopts, main, option_help_msgid): * src/sdiff.c (longopts, option_help_msgid, main): * src/io.c (find_and_hash_each_line): * src/util.c (lines_differ, analyze_hunk): Support -Z.
* diff: --ignore-file-name-case now applies at top level tooTim Waugh2011-08-131-1/+1
| | | | | | | | | | | Derived from Tim Waugh's patch in: http://lists.gnu.org/archive/html/bug-diffutils/2011-08/msg00034.html * NEWS, doc/diffutils.texi (diff Options): Document this. * src/diff.c (compare_files): Implement this, by using find_dir_file_pathname. * src/diff.h (find_dir_file_pathname): New decl. * src/dir.c: Include filenamecat.h. (find_dir_file_pathname): New function.
* doc: insert comma in --help line for --ignore-space-change (-b)Santiago Vila2011-08-081-1/+1
| | | | | * src/diff.c (option_help_msgid): Insert omitted comma between "-b" and "--ignore-space-change". (tiny change)
* build: ccache works better without embedded version stringsJim Meyering2011-06-131-1/+1
| | | | | | | | | | | | | * src/Makefile.am: Generate version.c and version.h and put the new symbol in a tiny library to be used by each program. (LDADD): Add the new library. * src/cmp.c (main): Use Version, not PACKAGE_VERSION, so the .o file does not change with each commit-derived version increment. * src/diff.c (main): Likewise. * src/diff3.c (main): Likewise. * src/sdiff.c (main): Likewise. * src/system.h: Include "version.h". * .gitignore: Add version.[ch]
* cmp, diff, diff3, sdiff: edit and align --help text.Karl Berry2011-06-081-56/+69
| | | | | | | | * cmp.c (option_help_msgid, usage), * diff.c (option_help_msgid, usage), * diff3.c (option_help_msgid, usage), * sdiff.c (option_help_msgid, usage): align descriptions in the --help output and slightly edit content.
* docs: diff --help should mention -LEric Blake2011-03-181-1/+1
| | | | * src/diff.c (option_help_msgid): Document -L.
* maint: avoid new syntax-check failureJim Meyering2011-01-231-1/+1
| | | | | * src/diff.c (specify_value): Use !STREQ(...), not strcmp(...) != 0. * src/diff3.c (main): Likewise.
* maint: update copyright year ranges to include 2011Jim Meyering2011-01-031-1/+1
| | | | Run "make update-copyright", so "make syntax-check" works in 2011.
* diff -r: avoid printing excess slashes in concatenated file namesJim Meyering2010-08-141-3/+4
| | | | | | | | | | | | * bootstrap.conf (gnulib_modules): Add filenamecat. * src/diff.c: Include "filenamecat.h". (compare_files): Use file_name_concat, rather than dir_file_pathname. * src/util.c (dir_file_pathname): Remove now-unused function. * src/diff.h: Remove its declaration. * tests/excess-slash: New script to test for this. * tests/Makefile.am (TESTS): Add it. Forwarded by Santiago Vila from <bugs.debian.org/586301a>, reported by Jari Aalto.
* portability: avoid "diff - ..." failure at least on *BSD and SolarisJim Meyering2010-02-101-1/+1
| | | | | | | The new "stdin" test was failing on many types of systems. * src/diff.c (compare_files): Guard use of xfreopen (NULL, "rb", ... also with O_BINARY, so as to avoid this unnecessary call on systems where it's not needed (on some it fails with "Bad address".
* maint: update all FSF copyright year lists to include 2010Jim Meyering2010-01-011-2/+2
| | | | | | Use this command: git ls-files |grep -vE '^(\..*|COPYING|gnulib)$' |xargs \ env UPDATE_COPYRIGHT_USE_INTERVALS=1 build-aux/update-copyright
* use xfreopen rather than freopenJim Meyering2009-11-201-3/+4
| | | | | | | | | * src/cmp.c: Include "xfreopen.h". Use xfreopen in place of freopen. * src/diff.c Likewise, and... (main): Set exit_failure to EXIT_TROUBLE, rather than to 2. * src/diff3.c: Likewise. * bootstrap.conf (gnulib_modules): Add xfreopen.
* maint: add an assertion to suppress clang-detected warningJim Meyering2009-11-201-2/+6
| | | | | | | | The clang static analyzer reported that a NULL parent could be dereferenced. However, that cannot happen, because for all callers, the parameter, parent, is always non-NULL at that point. * src/diff.c: Include <assert.h>. Assert that parent is not NULL.
* maint: define/use PROGRAM_NAME and AUTHORS; use propername moduleJim Meyering2009-11-161-3/+12
| | | | | | | | | | * bootstrap.conf (gnulib_modules): Add propername. * src/cmp.c (PROGRAM_NAME, AUTHORS): Define. (main): Use them in use of version_etc. * src/diff.c (PROGRAM_NAME, AUTHORS, main): Likewise. * src/diff3.c (PROGRAM_NAME, AUTHORS, main): Likewise. * src/sdiff.c (PROGRAM_NAME, AUTHORS, main): Likewise. * src/system.h: Include "propername.h".
* maint: bug-diffutils@gnu.org is the new bug-reporting addressJim Meyering2009-11-161-2/+1
| | | | | | | | | | | * configure.ac (AC_INIT): Use bug-diffutils@..., not bug-gnu-utils as the bug-reporting address. * NEWS (Administrivia): Mention this. * src/cmp.c (usage): Remove hard-coded address. Instead, use gnulib's emit_bug_reporting_address function. * src/diff.c (usage, option_help_msgid): Likewise. * src/diff3.c (usage): Likewise. * src/sdiff.c (usage): Likewise.
* admin: update all copyright notices to include the year 2009Jim Meyering2009-11-111-2/+2
|
* build: rely on gnulib's progname moduleJim Meyering2009-11-111-6/+2
| | | | | | | | | | | | * bootstrap.conf (gnulib_modules): Add progname. * cfg.mk (local-checks-to-skip): Add sc_program_name. * src/cmp.c: Include progname.h. (program_name): Remove declaration. (main): Call set_program_name. * src/diff.c (main): Likewise. * src/diff3.c (main): Likewise. * src/sdiff.c (main): Likewise. * src/diff.h (program_name): Remove extern declaration.
* maint/sc: use STREQ, not strcmp(a,b) == 0Jim Meyering2009-11-111-3/+3
| | | | | | | | | | | | | Run this command: git grep -l 'strcmp *([^=]*== *0'|xargs \ perl -pi -e 's/\bstrcmp( *\(.*?\)) *== *0/STREQ$1/g' and then add the new definition. * src/system.h (STREQ): Define. * src/cmp.c (main): Use STREQ, not strcmp. * src/diff.c (main, compare_files): Likewise. * src/diff3.c (main): Likewise. * src/sdiff.c (expand_name): Likewise. * cfg.mk (local-checks-to-skip): Add sc_prohibit_strcmp.
* maint/sc: remove useless if-before-free testsJim Meyering2009-11-111-4/+2
| | | | | | * src/diff.c (compare-files): Remove useless if stmts. * src/dir.c (diff_dirs): Likewise. * cfg.mk (local-checks-to-skip): Remove sc_avoid_if_before_free.
* * NEWS: New diff option --suppress-blank-empty (no longer -u default).Paul Eggert2009-11-111-0/+7
| | | | | | | | | | | | * doc/diff.texi (Detailed Unified): Trailing spaces are no longer omitted. (Trailing Blanks): New section. (diff Options) Mention new option. * src/diff.h (suppress_blank_entry): New decl. * src/context.c (pr_unidiff_hunk): Support --suppress-blank-empty. * src/util.c (print_1_line): Likewise. * src/diff.c (longopts, main, option_help_msgid): Likewise. (SUPPRESS_BLANK_EMPTY_OPTION): New constant.
* * src/diff.c (compare_files): Use last_component rather than base_name,Paul Eggert2009-11-111-1/+1
| | | | | | adjusting to gnulib API change. This avoids a memory leak. * src/sdiff.c (expand_name): Likewise. * src/util.c (dir_file_pathname): Likewise.
* * COPYING: New file.Paul Eggert2007-07-191-9/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * AUTHORS: Update from GPLv2 to GPLv3. * Makefile.am: Likewise. * NEWS: Likewise. * README: Likewise. * README-hacking: Likewise. * bootstrap: Likewise. * bootstrap.conf: Likewise. * configure.ac: Likewise. * exgettext: Likewise. * doc/Makefile.am: Likewise. * lib/Makefile.am: Likewise. * lib/cmpbuf.c: Likewise. * lib/cmpbuf.h: Likewise. * lib/prepargs.c: Likewise. * m4/vararrays.m4: Likewise. * man/Makefile.am: Likewise. * ms/Makefile.am: Likewise. * ms/README: Likewise. * ms/config.bat: Likewise. * ms/config.sed: Likewise. * ms/config.site: Likewise. * po/POTFILES.in: Likewise. * src/Makefile.am: Likewise. * src/analyze.c: Likewise. * src/cmp.c: Likewise. * src/context.c: Likewise. * src/diff.c: Likewise. * src/diff.h: Likewise. * src/diff3.c: Likewise. * src/dir.c: Likewise. * src/ed.c: Likewise. * src/io.c: Likewise. * src/normal.c: Likewise. * src/sdiff.c: Likewise. * src/system.h: Likewise. * src/util.c: Likewise.
* * bootstrap: Sync from gnulib.Paul Eggert2007-04-041-2/+1
| | | | | | | | | | * src/cmp.c: Don't include exit.h; no longer needed. * src/diff.c: Likewise. * src/sdiff.c: Likewise. * src/dir.c: Don't include strcase.h; no longer needed. * README-alpha: Remove, replacing with: * README-hacking: New file, taken from coreutils with some changes. The rename is required by the change to 'bootstrap'.
* Update FSF address.Paul Eggert2006-01-051-1/+1
|
* * src/cmp.c: Don't include <setmode.h>.Paul Eggert2006-01-051-274/+242
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (specify_ignore_initial): Reword to avoid gcc -W warnings. (main): Use freopen instead of setmode, since freopen is in POSIX. * src/context.c: Revert most 2004-09-01 changes. Then: (TIMESPEC_NS): Remove. All uses replaced by get_stat_mtime_ns. Include stat-time.h, strftime.h. (nstrtime): Remove decl. * src/diff.c: Revert most 2004-09-01 changes. Then: Don't include <posixver.h>, <quotesys.h>, <setmode.h>. Include <sh-quote.h>, <stat-time.h>, <timespec.h>. All uses of quotesys replaced by sh-quote. (main, compare_files): Use freopen instead of setmode, since freopen is in POSIX. (main): Don't complain about "diff -NUM'. (main, set_mtime_to_now): Adjust to stat-time.h macros when accessing nanoseconds. * src/diff3.c: Include sh-quote.h rather than quotesys. All uses changed. * src/dir.c (dir_read): excluded_filename renamed to excluded_file_name. * src/io.c: Don't include <setmode.h>. (sip, read_files): Remove binary file stuff, leaving a FIXME behind. A DOS expert needs to look at this. * src/diff.c: Include sh-quote.h rather than quotesys.h. All uses changed. * src/system.h: Include verify.h. (verify): Remove. All uses changed to verify.h version. Include <intprops.h>. (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove. Now uses intprops.h versions. (O_BINARY): New defns, taken from coreutils. * src/util.c: Include sh-quote.h rather than quotesys.h. All uses changed.
* (recursive, new_file, unidirectional_new_file,Paul Eggert2004-09-011-273/+271
| | | | | | | | | | | | | | | | report_identical_files): Move into struct diffopt. All uses changed. (exclude_options, compare_files, specify_style, check_stdout): New arg OPT. All uses changed. (GDIFF_MAIN): Remove. All uses removed. (function_regexp_list, ignore_regexp_list): No longer static; now locals in 'main'. (main): Set opt.function_regexp, opt.ignore_regexp if using regexps; all other code now tests these pointers rather than inspecting fastmap internals. New local OPT to hold former statics; initialize it. (init_regexp_list): New function, used by main. (summarize_regexp_list): Now returns struct re_pattern_buffer *, and assumes reglist->regexps is not NULL. All uses changed.
* Do not include regex.h, as diff.h does this now.Paul Eggert2004-04-121-64/+78
| | | | | | | | | | | | | | | | | (option_help_msgid): Mention exit status. (main): Adjust to latest gnulib c_stack_action calling conventions. Adjust to latest version_etc calling conventions. Include <exit.h>. (binary): Define to true if not declared. (longopts): Set tabsize flag to 1. (main): Don't output nanoseconds if platform lacks them. Don't treat files as binary if !binary. (set_mtime_to_now): Use 0, not NULL. (compare_files): Mark files as nonexistent if it looks like 'patch' created inaccessible regular empty files to denote nonexistent backups. Don't compare such files. Clear st_* members of status of nonexistent file. Remove now-unnecessary tests.
* Include version-etc.h, not freesoft.h.Paul Eggert2002-06-171-8/+2
| | | | | (copyright_notice): Remove. (main): Use version_etc to print version.
* Include <file-type.h>.Paul Eggert2002-06-111-64/+46
| | | | | | | | | | | | | Include paths.h. (copyright_notice): Renamed from copyright_string. Now a msgid, so that copyright symbol can be translated. All uses changed. Include posixver.h. (TABSIZE_OPTION): New constant. (main): Allow widths up to SIZE_MAX. (filetype): Move to lib/file-type.c and rename to file_type. All uses changed. (longopts, main, usage): New option --tabsize=COLUMNS.
* (main): Fix typo that prevented diff -y from working. Bug reported byPaul Eggert2002-03-241-4/+5
| | | | Mitsuru Chinen.
* (option_help_msgid): Bring back --horizon-lines documentation.Paul Eggert2002-03-121-0/+1
|
* (option_help_msgid): Do not document -L, -P, --horizon-lines,Paul Eggert2002-03-121-7/+7
| | | | --inhibit-hunk-merge, -H.
* (option_help_msgid): Reword for help2man.Paul Eggert2002-03-111-4/+6
|
* (LONG_OPTION, GROUP_FORMAT_OPTION, LINE_FORMAT_OPTION): Remove.Paul Eggert2002-02-281-13/+4
| | | | (longopts): Revert to prevision version.
* Include c-stack.h, exitfail.h.Paul Eggert2002-02-281-225/+261
| | | | | | | | | | | | | | | | | | | | | | | | | | | Do not include signal.h. (specify_style, specify_value): Bring these routines back, as POSIX requires that the order of options not matter. (shortopts): New constant. (group_format_option, line_format_option): New constants. (LONG_OPTION, GROUP_FORMAT_OPTION, LINE_FORMAT_OPTION): New macros. (longopts): Use them. (main): 0 -> EXIT_SUCCESS, 1 -> EXIT_FAILURE, 2 -> EXIT_TROUBLE. Ensure that order of options does not matter. Check for stack overflow. If contexts overflow, substitute LIN_MAX, as that's good enough. If multiple contexts are specified, use their maximum. -c is equivalent to -C 3 now, instead of having an implicit context; likewise for -u and -U 3. Use specify_style and specify_value. (SIGCHLD): Do not define; now done in a header. Use new style time stamp format for -u / -U. Reject numeric-string options if operating in POSIX 1003.1-2001 mode. Avoid overflow problems with tab width. Simplify from-file and to-file code. (usage): Do not mention obsolete options. (filetype): Do not mention whether a file is executable. Add typed memory objects. (compare_files): 0 -> EXIT_SUCCESS, 1 -> EXIT_FAILURE, 2 -> EXIT_TROUBLE.
* (copyright_string): Update to 2002.Paul Eggert2002-01-241-3/+3
| | | | | (usage): Reformat messages to ease translation. (main): Remove unused variable.
* (DEFAULT_WIDTH): Remove.Paul Eggert2001-12-241-11/+8
| | | | | | | | (main): Use 130 instead of DEFAULT_WIDTH, since it's not really builder-settable. Do not prepend DIFF_OPTIONS. (check-stdout): If fclose (stdout) fails, print errno info. (option_help_msgid): Default context is 3, not 2. (usage): Work even if ptrdiff_t is wider than int.
* Include dirname.h, setmode.h.Paul Eggert2001-12-111-80/+79
| | | | | | | | | | | | | | | | | (main): Later values and/or styles now silently override earlier. (specify_value, specify_style): Likewise. All callers changed. Remove. (binary, main, option_help_msgid, compare_files): HAVE_SETMODE -> HAVE_SETMODE_DOS. (NO_IGNORE_FILE_NAME_CASE_OPTION): New constant. (longopts, main, option_help_msgid): Support it. (exclude_options): New function. (main): Use it. Initialize xalloc_exit_failure before potentially allocating memory. (filetype): Distinguish executable files from others, as POSIX suggests. (compare_files): Use base_name instead of file_name_lastdirchar.
* (main, compare_files): setmode -> set_binary_mode.Paul Eggert2001-12-031-10/+10
|
* (option_help_msgid): Don't mention --binary on POSIX hosts.Paul Eggert2001-11-251-2/+0
|
* Assume C89 or better.Paul Eggert2001-11-241-418/+431
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | int -> bool for booleans. long -> off_t for line numbers. Use angle-brackets when including getopt.h, fnmatch.h, quotesys.h. Include error.h, exclude.h, freesoft.h, hard-locale.h, prepargs.h, regex.h, signal.h, xalloc.h. (copyright_string): Use only most recent year. (authorship_msgid, option_help_msgid): Wrap in N_(). Rename the following variables for consistency with user-visible option spellings. All uses changed. (binary): Renamed from binary_flag. (new_file): Renamed from entire_new_file_flag. (unidirectional_new_file): Renamed from unidirectional_new_file_flag. (report_identical_files): Renamed from print_file_same_flag. (numeric_arg): Remove. (exclude, exclude_alloc, exclude_count, excluded_filename, add_exclude, add_exclude_file): Remove; now done by exclude.h. (BINARY_OPTION, FROM_FILE_OPTION, HELP_OPTION, HORIZON_LINES_OPTION, IGNORE_FILE_NAME_CASE_OPTION, INHIBIT_HUNK_MERGE_OPTION, LEFT_COLUMN_OPTION, LINE_FORMAT_OPTION, NORMAL_OPTION, SDIFF_MERGE_ASSIST_OPTION, STRIP_TRAILING_CR_OPTION, SUPPRESS_COMMON_LINES_OPTION, TO_FILE_OPTION, UNCHANGED_LINE_FORMAT_OPTION, OLD_LINE_FORMAT_OPTION, NEW_LINE_FORMAT_OPTION, UNCHANGED_GROUP_FORMAT_OPTION, OLD_GROUP_FORMAT_OPTION, NEW_GROUP_FORMAT_OPTION, CHANGED_GROUP_FORMAT_OPTION): New constants. (longopts, main): Use them. (longopts, main, option_help_msgid): Add -E, --from-file, --to-file. (main): Invoke bindtextdomain and textdomain after setlocale. Use grep syntax, not Emacs, for regular expressions. Use exclude.h, not our own functions. Use ISO 8601 time format in hard locales. Prepend DIFF_OPTIONS. Don't update ignore_some_changes. Use strtoumax instead of numeric_arg. Use specify_value when appropriate. error -> try_help when appropriate. -p now means ^[[:alpha:]$_], not ^[_a-zA-Z$]. Ignore --inhibit-hunk-merge. Prefer changed group formats to unchanged ones. Remove now-unnecessary casts. Set files_can_be_treated_as_binary. (specify_value): Renamed from specify_format. All uses changed. (specify_style): Default is now unspecified, not normal. All uses changed. (set_mtime_to_now): New function. (compare_files): Use it. Use memset, not bzero. Set stdin mtime to current time even when stdin is not a regular file. Check for same file attributes, as well as for same file. Use files_can_be_treated_as_binary. "write failed" -> "standard output on output failure.
* Include <config.h> before using "const".Paul Eggert1998-09-141-2/+3
|
* (authorship_msgid): New var.Paul Eggert1998-09-141-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (quotesys.h): Include. (ck_atoi): Remove. (function_regexp_list, ignore_regexp_list): Now static. (binary_flag): Renamed from binary_I_O. (entire_new_file_flag, unidirectional_new_file_flag, print_file_same_flag): Now static. (numeric_arg): Renamed from ck_atoi. New argument specifying the argument type. (longopts, main): Don't assume ASCII. (longopts): Remove old aliases --file-label, --entire-new-file, --ascii, --print. (main): Check for -1, not EOF, when calling getopt_long. Use numeric_arg to report errors. Report error if -l specified but pagination is not supported. Report error if -S is specified twice with conflicting values. Have --version conform to the new GNU standards. Add new --from-file, --to-file, --inhibit-hun,-merge options. Make the horizon at least as large as the context. Add casts to pacify gcc -Wall. (try_help): Add operand arg. (option_help_msgid): Doc fix to match above. (usage): Indent option_help_msgid. (compare_files): Now takes struct comparison instead of two directory names and a depth. (NONEXISTENT, UNOPENED, ERRNO_ENCODE, ERRNO_DECODE): New macros. (DIR_P): New macro. Report error if fflush does.
* (authorship_msgid): New var.Paul Eggert1998-09-131-290/+434
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (quotearg.h): Include. (ck_atoi): Remove. (function_regexp_list, ignore_regexp_list): Now static. (binary_flag): Renamed from binary_I_O. (entire_new_file_flag, unidirectional_new_file_flag, print_file_same_flag): Now static. (numeric_arg): Renamed from ck_atoi. New argument specifying the argument type. (longopts, main): Don't assume ASCII. (longopts): Remove old aliases --file-label, --entire-new-file, --ascii, --print. (main): Check for -1, not EOF, when calling getopt_long. Use numeric_arg to report errors. Report error if -l specified but pagination is not supported. Report error if -S is specified twice with conflicting values. Have --version conform to the new GNU standards. Add new --from-file, --to-file, --inhibit-hun,-merge options. Make the horizon at least as large as the context. Add casts to pacify gcc -Wall. (try_help): Add operand arg. (option_help_msgid): Doc fix to match above. (usage): Indent option_help_msgid. (compare_files): Now takes struct comparison instead of two directory names and a depth. (NONEXISTENT, UNOPENED, ERRNO_ENCODE, ERRNO_DECODE): New macros. (DIR_P): New macro. Report error if fflush does.
* (main): Invoke setlocale first thing, to tell library we're internationalized.Paul Eggert1994-11-141-95/+111
| | | | | | | -D FOO now outputs `/* ! FOO */ instead of `/* not FOO */'. (option_help_msgid): New constant. (usage): Use it, so message is translated one option at a time. (compare_files): For label, use file_label if set.
* (option_list): Quote options with system_quote_arg.Paul Eggert1994-10-311-23/+78
| | | | | | | (add_regexp): Build one big regexp instead of a list of regexps. (summarize_regexp_list): New function. (regexp_list): Redesigned struct; moved here from diff.h. (function_regexp_list, ignore_regexp_list): Likewise, for vars.
* (add_exclude): Can now assume xrealloc (0, ...) works.Paul Eggert1994-10-151-29/+32
| | | | (add_regexp): Free storage on failure. Allocate storage all at one go.