| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
| |
Run "make update-copyright".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* tests/binary: Reverse arguments to compare to avoid failure of
new syntax-check rule.
* configure.ac: Use -Wno-format-nonliteral.
Mark functions as pure of const, per recommendations enabled by
new gcc -W options. Use _GL_ATTRIBUTE_PURE and _GL_ATTRIBUTE_CONST.
* lib/cmpbuf.h (buffer_lcm, block_compare):
Apply pure and/or const attributes.
* src/cmp.c (block_compare): Likewise.
* src/context.c (find_hunk): Likewise.
* src/diff.h (lines_differ): Likewise.
* src/diff3.c (skipwhite): Likewise.
* src/dir.c (dir_loop): Likewise.
* src/util.c (find_change, find_reverse_change): Likewise.
(translate_line_number): Likewise.
|
|
|
|
|
| |
* src/diff.h (find_dir_file_pathname): Mark declaration with "extern"
keyword, in order to placate the tight-scope syntax check.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
| |
* src/diff.h: Mark function declarations with "extern" in
preparation for the tight-scope check.
(ignore_white_space): Separate enum decl from declaration
of this variable.
* src/Makefile.am (diff_SOURCES): Move diff.h from here to ...
(noinst_HEADERS): ...here.
For convenience, since the tight-scope rule uses $(noinst_HEADERS).
|
|
|
|
| |
Run "make update-copyright", so "make syntax-check" works in 2011.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
|
|
| |
Use this command:
git ls-files |grep -vE '^(\..*|COPYING|gnulib)$' |xargs \
env UPDATE_COPYRIGHT_USE_INTERVALS=1 build-aux/update-copyright
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
| |
|
|
|
|
|
|
| |
(struct file_data.changed): Now char *, not bool *, to save
space on hosts where bool takes more space than char.
All uses changed.
|
| |
|
|
|
|
|
|
| |
(tabsize): New decl.
(sdiff_half_width, sdiff_column2_offset): Now size_t rather than
unsigned int.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
int -> bool for booleans.
int -> lin for line numbers.
Don't include regex.h.
(enum changes): New enum.
(enum line_class): Remove; subsumed by enum changes.
(enum output_style): New constant OUTPUT_UNSPECIFIED.
(ignore_space_change_flag, ignore_all_space_flag): Remove.
(ignore_white_space): New decl, subsuming the above two. All uses changed.
Rename the following decls for consistency with user-visible
option spellings. All uses changed.
(text): Renamed from always_text_flag.
(ignore_blank_lines): Renamed from ignore_blank_lines_flag.
(ignore_case): Renamed from ignore_case_flag.
(brief): Renamed from no_details_flag.
(initial_tab): Renamed from tab_align_flag.
(expand_tabs): Renamed from tab_expand_flag.
(starting_file): Renamed from dir_start_file.
(paginate): Renamed from paginate_flag.
(sdiff_merge_assist): Renamed from sdiff_help_sdiff.
(left_column): Renamed from sdiff_left_only.
(suppress_common_lines): Renamed from sdiff_skip_common_lines.
(speed_large_files): Renamed from heuristic.
(minimal): Renamed from no_discards.
(inhibit_hunk_merge): Remove.
(strip_trailing_cr, excluded, time_format): New decls.
(files_can_be_treated_as_binary): Renamed from ignore_some_changes.
(group_format, line_format): Now char const *[], not char *[].
(struct file_data): Buffer is now word*, not char*, as it's always
aligned and this can help the compiler. buffered_chars -> buffered
(since it's a byte count, not a char count). All uses changed.
New member `eof'.
(FILE_BUFFER): New macro.
(excluded_filename, error, free_software_msgid): Remove decls; now in
other .h files.
(sip, slurp): Remove decls.
(file_block_read): New decl.
(change_letter): Now an array, not a function.
(lines_differ): Renamed from line_cmp.
(analyze_hunk): Now returns enum changes rather than two change counts.
|
|
|
|
|
|
|
|
|
|
|
| |
(struct filedata): Remove dir_p arg.
(struct comparison): New type.
(diff_2_files, diff_dirs)" Ise ot/
(error): Add printf attribute if applicable.
(free_software_msgid): New decl.
(pr_program): New decl.
(fatal): Add noreturn attribute.
(pfatal_with_name): Likewise.
|
|
|
|
|
|
|
|
|
|
|
| |
(struct filedata): Remove dir_p arg.
(struct comparison): New type.
(diff_2_files, diff_dirs)" Ise ot/
(error): Add printf attribute if applicable.
(free_software_msgid): New decl.
(pr_program): New decl.
(fatal): Add noreturn attribute.
(pfatal_with_name): Likewise.
|
|
|
|
|
| |
these single compiled regexps.
(regexp_list, function_regexp_list, ignore_regexp_list): Moved to diff.c.
|
|
|
|
|
|
| |
(error): Change to GNU library standard. All callers changed.
(xmalloc_exit_failure): New variable. xmalloc and xrealloc are now taken
from GNU library. All `main' programs set this variable at the start.
|
|
|
|
| |
(PR_FILE_NAME): Rename to PR_PROGRAM and move to Makefile.in, util.c.
|
| |
|
|
|
|
|
| |
(line_end_char): Removed; it wasn't being used consistently.
(line_cmp): Now takes just pointers to two lines.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
Use `const' when needed to pacify gcc.
(Is_space, textchar): Remove.
(struct msg, msg_chain, msg_chain_end): Move to util.c.
(VOID): Move to system.h.
(line_cmp, version_string, change_letter, print_number_range,
find_change): New decls.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|