| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
| |
Requested by Dan Jacobson (Bug#22816).
* NEWS:
* doc/diffutils.texi (Invoking cmp, cmp Options): Document this.
* src/cmp.c (cmp): Implement it.
* tests/Makefile.am (TESTS): Add cmp.
* tests/cmp: New file.
|
|
|
|
|
|
| |
* NEWS (Bug fixes): Describe it.
* tests/invalid-re: New test for just-fixed bug.
* tests/Makefile.am (TESTS): Add it.
|
| |
|
|
|
|
|
|
| |
Problem reported by Marcel Böhme in:
http://lists.gnu.org/archive/html/bug-diffutils/2017-04/msg00002.html
* src/diff.c (add_regexp): Exit if re_compile_pattern fails.
|
|
|
|
|
|
|
| |
* tests/brief-vs-stat-zero-kernel-lies: Use "test -r" rather than
just "test -f". This avoids a false test failure on a linux system
with grsecurity and its GRKERNSEC_PROC_USER option enabled, for which
/proc/cmdline is unreadable. Reported in https://bugs.gnu.org/26155
|
|
|
|
|
|
|
|
| |
* tests/colors: Move the TERM=dumb setting into the code run by
"returns_", since some shells do not propagate envvar setting through
to a use of a function like this. That would cause this test to fail
because results were colorized when they should not have been.
Reported by Nelson Beebe.
|
|
|
|
| |
* NEWS: Update. Also, thanks to Nelson Beebe for reporting this.
|
|
|
|
|
|
|
| |
* src/diff.c (main): Always define presume_output_tty.
Otherwise, it would be read uninitialized.
Introduced in v3.3-45-g17e2698
* NEWS (Bug fixes): Mention it.
|
| |
|
|
|
|
|
|
|
|
| |
This avoids a new syntax-check failure.
* ChangeLog-2008: Perform that change.
* doc/diffutils.texi: Likewise.
* NEWS: Likewise.
* cfg.mk: Update the old news hash accordingly.
|
|
|
|
|
| |
* gnulib: Update to latest.
* all files: Run "make update-copyright".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* tests/colors: Use "returns_ 1" rather than testing $? = 1
* tests/basic: Likewise.
* tests/binary: Likewise.
* tests/filename-quoting: Likewise.
* tests/function-line-vs-leading-space: Likewise.
* tests/ignore-matching-lines: Likewise.
* tests/label-vs-func: Likewise.
* tests/new-file: Likewise.
* tests/no-dereference: Likewise.
* tests/no-newline-at-eof: Likewise.
* tests/stdin: Likewise.
|
|
|
|
|
|
|
|
|
| |
* NEWS, doc/diffutils.texi (Overview): Document this.
* src/analyze.c (diff_2_files): Restore too_expensive heuristic,
but this time with a floor that is 16 times the old floor. This
should fix Bug#16848, by generating good-quality output for its
test case, while not introducing Bug#24715, by running nearly as
fast as diff-3.3 for that test case.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use "die (N, ..." rather than "error (N, ..." whenever N is a nonzero
constant. That lets the compiler know that control never goes beyond
that point, and thus makes unnecessary the occasional following
"abort ();" or "break;" statement we have historically added to inform
static analysis tools of this aspect of "error" semantics.
* src/die.h: New file.
* src/Makefile.am (noinst_HEADERS): Add it.
* src/cmp.c: Use die in place of error whenever the first
argument is a nonzero constant. Also remove any immediately-
following call to abort, and include "die.h".
* src/diff.c: Likewise.
* src/diff3.c: Likewise.
* src/sdiff.c: Likewise.
* src/util.c: Likewise.
|
| |
|
|
|
|
|
|
|
|
| |
* src/util.c (get_funky_string): Adjust comment so that GCC 7's
-Wimplicit-fallthrough recognizes it.
* src/diff3.c (main): Cast boolean MERGE to "int" to avoid this:
diff3.c:341:25: error: '~' on a boolean expression \
[-Werror=bool-operation]
|
| |
|
|
|
|
|
|
|
| |
This fixes compilation errors when using gcc-7-to-be that were
due to missing backslashes in gnulib's intprops.h and an API
change in functions like __builtin_add_overflow. This ports
to GCC 7's newer built-in overflow-checking functions.
|
|
|
|
|
| |
* src/system.h (printint, pI): Port to (theoretical) platforms
where ptrdiff_t is wider than long long int (Bug#24311).
|
|
|
|
|
|
|
|
| |
Problem reported by Peter Rosin (Bug#24311).
* src/system.h (printint, pI): New typedef and macro.
All uses of 'long int' and "%l" in printf format replaced by
'printint' and "%"pI respectively.
* src/ifdef.c (do_printf_spec): Don't assume pI is length 1.
|
|
|
|
|
|
| |
* NEWS: Add header line for next release.
* .prev-version: Record previous version.
* cfg.mk (old_NEWS_hash): Auto-update.
|
|
|
|
| |
* NEWS: Record release date.
|
|
|
|
|
|
| |
* configure.ac (WERROR_CFLAGS): Add -fno-common, when possible.
This would have prevented the duplicate definition of
presume_output_tty that was fixed in v3.4-10-gc2dc91f.
|
|
|
|
|
| |
* src/util.c (presume_output_tty): Remove this definition.
The other is in diff.h. Reported in https://bugs.gnu.org/24248
|
| |
|
|
|
|
|
|
| |
* tests/diff3 (seq): Provide a seq replacement function,
since at least AIX, SunOS 5.10, OpenBSD-5.8 lack it.
Reported by Assaf Gordon in https://bugs.gnu.org/24227#8
|
|
|
|
|
|
| |
* src/diff3.c (struct diff_block)[lint]: Add member, n2.
(free_diff_block, next_to_n2): New functions.
* tests/diff3: Add more test coverage.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bootstrap.conf (bootstrap_epilogue): Merge from coreutils, so that
a local commit hook will now help enforce consistent commit messages.
* Makefile.am (check-git-hook-script-sync): New rule, largely copied
from coreutils.
* scripts/git-hooks/commit-msg: New file, from coreutils, but
with adapted list of program names.
* scripts/git-hooks/applypatch-msg: New file, from git.
* scripts/git-hooks/pre-applypatch: Likewise.
* scripts/git-hooks/pre-commit: Likewise.
|
|
|
|
|
|
|
|
|
|
| |
Commit v3.3-42-g3b74a90, "FIXME: src/diff3: plug a leak" added an
invalid use of free, leading to use-after-free in nearly any invocation
of diff3. Revert that commit.
* NEWS (Bug fixes): Mention it.
* tests/diff3: New file, to add minimal test coverage.
* tests/Makefile.am (TESTS): Add it.
Reported by Bastian Beischer in http://bugs.gnu.org/24210
|
|
|
|
| |
* .gitignore: Ignore texinfo artifacts in doc/.
|
|
|
|
| |
* src/diff3.c (main): Remove unreachable "return" after exit from main.
|
|
|
|
|
|
|
|
| |
* src/diff.c (main): With --color or --color=auto, when TERM is
"dumb", disable colorization. Suggested by Daniel Colascione.
* NEWS (Bug fixes): Mention it.
* tests/colors: Add a test that would fail without this change,
yet passes with it.
|
|
|
|
|
|
| |
* NEWS: Add header line for next release.
* .prev-version: Record previous version.
* cfg.mk (old_NEWS_hash): Auto-update.
|
|
|
|
| |
* NEWS: Record release date.
|
| |
|
|
|
|
|
|
|
| |
* tests/Makefile.am (built_programs): Adjust to work around what
may be a problem due to interaction between Solaris 10's /bin/sh
and an old version of GNU make. Reported by Dagobert Michelsen
in https https://bugs.gnu.org/24137.
|
| |
|
|
|
|
|
|
| |
* tests/brief-vs-stat-zero-kernel-lies: The Hurd's /proc/self
is not useful, so detect that and skip the test that requires it.
Reported by Assaf Gordon in https://debbugs.gnu.org/24121#29
|
|
|
|
|
|
| |
* tests/colors (epoch): Don't use GNU touch's --date=$epoch option.
Use the portable -t 197001010000.00.
Reported by Assaf Gordon in https://debbugs.gnu.org/24121#8
|
|
|
|
|
| |
* bootstrap.conf (gnulib_modules): Add isblank, to avoid a link
error on Solaris 9 Sparc. Reported by Dagobert Michelsen.
|
|
|
|
|
|
|
| |
* tests/envvar-check: New file, copied from grep, with the addition
of the EDITOR and GREP_OPTIONS envvar names.
* tests/Makefile.am (EXTRA_DIST): Add it.
(TESTS_ENVIRONMENT): Revamp, to be more like that of grep.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* gl/lib/regcomp.c.diff: Remove file, now that gnulib's
regcomp.c compiles regex.c with -Wno-unused-parameter.
* gl/lib/regex_internal.c.diff: This file induced a change to ensure
that the "Idx" type was unsigned and to remove a few "VAR < 0"
comparisons. These days, it is probably fine to stay in sync with
gnulib/glibc's copies
of these files, so remove these patches, too.
* gl/lib/regexec.c.diff: Likewise.
Prompted by a report by Assaf Gordon and a suggestion from Paul Eggert.
|
|
|
|
|
|
|
|
|
|
| |
* tests/colors (e): Fix a portability bug: use printf '\033'
rather than '\e' to generate the required byte sequence, since
for some shells (at least dash 0.5.8), the latter doesn't work.
Work around a shell bug whereby "local tab=$(printf '\t')"
would result in an empty value for "$tab": hoist each "tab"
definition up/out of its function to global scope.
Reported by Assaf Gordon in http://debbugs.gnu.org/24116#8
|
|
|
|
|
| |
* gnulib: Update to latest.
* init.sh: Update from gnulib.
|
|
|
|
|
| |
* dist-check.mk (my-distcheck): Remove all .deps directories
before performing the recursive comparison.
|
|
|
|
|
|
| |
* doc/diffutils.texi (Interactive Merging): Correct a reference to
emacs' emerge node: s/emerge/Emerge/.
This addresses http://debbugs.gnu.org/23613
|
|
|
|
|
| |
* cfg.mk (url_dir_list): Define. I had been correcting the generated
URLs by hand, just before the announcement. This is better.
|
|
|
|
|
| |
* Makefile.am (gen-ChangeLog): Don't ignore failure of
gitlog-to-changelog. This syncs to coreutils' copy of this rule.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* src/diff.h (presume_output_tty): New extern variable.
* src/diff.c (PRESUME_OUTPUT_TTY_OPTION): New enum.
(group_format_option): Add '-presume-output-tty'.
(main): Handle PRESUME_OUTPUT_TTY_OPTION.
* src/util.c: New variable `presume_output_tty'.
(check_color_output): Handle presume_output_tty.
(set_color_context): Call process_signals only when color_context is
not RESET_CONTEXT.
* tests/colors: Check that diff doesn't crash when interrupted
in the middle of a color sequence.
Reported by Gisle Vanem in http://debbugs.gnu.org/22067
|