summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* (diff_2_files): ignore_regexp_list -> ignore_regexp.fastmapPaul Eggert1994-10-311-3/+3
|
* (perror_with_name, fatal): Use GNU `error'.Paul Eggert1994-10-151-70/+14
| | | | | | (error): Remove. (line_cmp): tolower -> _tolower (xmalloc, xrealloc): Remove.
* (_tolower): Define if not already defined.Paul Eggert1994-10-151-8/+9
| | | | (malloc, realloc): Remove unused declarations.
* (xmalloc): Remove.Paul Eggert1994-10-151-38/+21
| | | | (diffarg): Take advantage of cleaner xrealloc semantics.
* (ROL): Use sizeof to make it more generic.Paul Eggert1994-10-151-51/+62
| | | | | | | | (slurp): Align buffer size to word size, in case malloc cares. (find_and_hash_each_line): Don't invoke line_cmp if the length differs and -i is in force. tolower -> _tolower; this speeds up diff -i considerably under some hosts (e.g. Solaris 2.3). Don't assume ISSPACE ('\n') is nonzero.
* (groups_letter_value): tolower -> _tolowerPaul Eggert1994-10-151-1/+1
|
* (main): Use strerror (EISDIR) instead of "Is a directory".Paul Eggert1994-10-151-44/+15
| | | | | (xmalloc, xrealloc): Remove. (fatal, perror_with_exit): Use `error'.
* (ignore_some_line_changes): Removed. All users changed.Paul Eggert1994-10-151-20/+21
| | | | | | (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.
* (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.
* (main): Align buffer size to word size, in case malloc cares.Paul Eggert1994-10-151-4/+7
|
* error caller changedPaul Eggert1994-10-151-1/+1
|
* (main): Set xmalloc_exit_failure.David MacKenzie1994-10-121-0/+2
|
* (dir_file_pathname): Use filename_lastdirchar instead of strrchr.Paul Eggert1994-10-011-1/+2
|
* (<sys/wait.h>, WEXITSTATUS): Use simpler scheme now that HAVE_SYS_WAIT_HPaul Eggert1994-10-011-10/+1
| | | | is turned off on hosts that are incompatible with Posix applications.
* (private_tempnam): Use tmpnam if HAVE_TMPNAM; this simplifies porting.Paul Eggert1994-10-011-4/+11
| | | | | (exists, letters): Omit if HAVE_TMPNAM. (expand_name): Use filename_lastdirchar instead of strrchr.
* (read_diff): If STAT_BLOCKSIZE yields zero, adjust it to a more reasonablePaul Eggert1994-10-011-2/+3
| | | | value.
* (exists, private_tempname): Adopt latest GNU libc algorithm.Paul Eggert1994-09-241-100/+46
| | | | (private_tempnam): Specialize for sdiff to avoid portability problems.
* isspace -> ISSPACE, etc.Paul Eggert1994-09-221-29/+26
| | | | | (PR_PROGRAM): Moved here from diff.h (old name was PR_FILE_NAME). (begin_output): Use SYSTEM_QUOTE_ARG.
* <string.h>: Include if HAVE_STRING_H, too.Paul Eggert1994-09-221-5/+41
| | | | | | | (CTYPE_DOMAIN, ISDIGIT, ISPRINT, ISSPACE, ISUPPER): New macros that work around common <ctype.h> problems. (O_BINARY): Remove. (SYSTEM_QUOTE_ARG): New macros.
* isprint -> ISPRINTPaul Eggert1994-09-221-2/+2
|
* isspace -> ISSPACE, etc.Paul Eggert1994-09-221-25/+20
| | | | | | | | | | <ctype.h> now included by system.h. (DEFAULT_EDITOR_PROGRAM): Renamed from DEFAULT_EDITOR for consistency. (TMPDIR_ENV): New macro. (expand_name): Change `isdir' to `is_dir' to avoid theoretical ctype namespace contamination. (main): Use SYSTEM_QUOTE_ARG. (private_tempnam): Don't access "/tmp" directly; access it via PVT_tmpdir.
* isspace -> ISSPACE, etc.Paul Eggert1994-09-221-14/+32
| | | | | (word): Don't define if already defined. (read_files): Set mode to binary before returning 1.
* isdigit -> ISDIGIT, etc.Paul Eggert1994-09-221-6/+6
|
* <ctype.h> now included by system.h.Paul Eggert1994-09-221-23/+6
| | | | | (main): Give proper diagnostic if too many labels were given. (read_diff): Use SYSTEM_QUOTE_ARG.
* <ctype.h> now included by system.h.Paul Eggert1994-09-221-5/+0
| | | | (PR_FILE_NAME): Rename to PR_PROGRAM and move to Makefile.in, util.c.
* Add comment.Paul Eggert1994-09-221-0/+4
|
* (word): Don't define if already defined.Paul Eggert1994-09-221-6/+11
| | | | | | (main): Use setmode, not open(..., O_BINARY); this hits stdin too. Use NULL_DEVICE instead of "/dev/null". (cmp): Use %lu instead of %ld when it is more likely to give correct output.
* (program_name): Renamed from `program', for consistency.Paul Eggert1994-09-155-24/+27
|
* (printc): Don't quote C if isprint(C).Paul Eggert1994-09-151-18/+21
|
* (memcmp): Define in terms of bcmp.Paul Eggert1994-09-131-2/+3
| | | | Use HAVE_MEMCHR to test for all mem* routines.
* (line_cmp): Now takes just two arguments, and no longer optimizesPaul Eggert1994-09-121-37/+45
| | | | | | | for common case of exact equality; the caller does that optimization now. Optimize for the common case of mostly exact equality. Use isupper/tolower instead of islower/toupper, for consistency. (line_cmp, print_line): Use '\n' instead of line_end_char.
* Use more modern autoconf approach to standard C headers.Paul Eggert1994-09-121-24/+17
|
* Fix copyright notice.Paul Eggert1994-09-126-8/+8
|
* (binary_file_p): Assume non-broken memchr.Paul Eggert1994-09-121-30/+49
| | | | | | | | | | (find_and_hash_each_line): Revamp to fix some inconsistencies with -b -w -i and incomplete lines. Incomplete lines are now put into their own bucket. This means line_cmp no longer needs line length arguments, and equivalence classes' line length no longer need to include \n. Invoke line_cmp only if memcmp fails and if ignore_some_line_changes. (prepare_text_end): -B no lonter ignores missing newlines. (read_files): Allocate another bucket for incomplete lines.
* (ignore_some_line_changes): New variable; replaces `length_varies'.Paul Eggert1994-09-121-6/+3
| | | | | (line_end_char): Removed; it wasn't being used consistently. (line_cmp): Now takes just pointers to two lines.
* (main): Use '\n', not line_end_char.Paul Eggert1994-09-121-4/+4
| | | | (ignore_some_line_changes): New variable; replaces `length_varies'.
* (memchr, waitpid): Remove; use new substitutes instead.Paul Eggert1994-09-081-25/+0
|
* Use Autoconf 2 style HAVE_DIRENT_H etc. macros for directories.Paul Eggert1994-09-081-15/+14
|
* (try_help): New function.Paul Eggert1994-09-081-62/+43
| | | | | (usage): Just print usage; let caller worry about exiting. (memchr, waitpid): Remove; use new substitutes instead.
* (dir_sort): Prefer NAMLEN (p) to strlen (p->d_name).Paul Eggert1994-09-081-3/+2
| | | | Change VOID_CLOSEDIR to CLOSEDIR_VOID for Autoconf 2.
* (try_help, check_stdout): New functions.Paul Eggert1994-09-081-32/+52
| | | | | (usage): Just print usage; let caller worry about exiting. (read_diff): Use new waitpid substitute.
* (try_help, check_stdout): New functions.Paul Eggert1994-09-081-39/+111
| | | | | | (usage): Just print usage; let caller worry about exiting. (option_help): New variable. (filetype): Add Posix.1b file types.
* (try_help, check_stdout): New functions.Paul Eggert1994-09-081-26/+40
| | | | (usage): Just print usage; let caller worry about exiting.
* (main): Call initialize_main first.Paul Eggert1994-09-021-15/+80
| | | | | | | If we'll have children, make sure SIGCHLD isn't ignored. (read_diff): Use popen+pclose if !HAVE_FORK. (DIFF_CHUNK_SIZE): Removed. We now get initial chunk size from STAT_BLOCKSIZE. (INT_STRLEN_BOUND): New macro.
* (ck_fdopen): Function removed.Paul Eggert1994-09-021-62/+119
| | | | | | | | | | | (cleanup, main, waitpid): Use popen+pclose if !HAVE_FORK. (edit): Use system if !HAVE_FORK. (main): Call initialize_main first. (execdiff): Now assumes caller has pushed all args, plus trailing 0. All callers changed. (trapsigs): If we'll have children, make sure SIGCHLD isn't ignored. (private_tempnam): Try TMP if TMPDIR isn't defined. Fit temporary filenames into 8.3 limit.
* Include <sys/file.h> only if HAVE_SYS_FILE_H.Paul Eggert1994-09-021-11/+43
| | | | | | | | (S_IXGRP, S_IXOTH, S_IXUSR): Remove unused macros. (STAT_BLOCKSIZE): Don't define if already defined. (min, max): Undef if already defined. (filename_cmp, filename_lastdirchar, HAVE_FORK, HAVE_SETMODE, initialize_main O_BINARY, same_file): New macros, for porting to non-Posix systems like DOS.
* (binary_I_O): New variable for --binary option.Paul Eggert1994-09-021-11/+40
| | | | | | | | | (main, usage, compare_files): Support --binary option. (main): Call initialize_main first. If we'll have children, make sure SIGCHLD isn't ignored. (compare_files): Use filename_cmp to compare file names. Use filename_lastdirchar to find last directory char in a file name. Use same_file to determine whether two files are the same.
* (begin_output): Use popen+pclose if !HAVE_FORK. Check fdopen status.Paul Eggert1994-09-021-4/+33
|
* (sip): If HAVE_SETMODE, always test for binary files using binary mode.Paul Eggert1994-09-021-6/+17
|
* (print_context_label): Check whether (broken) ctime yields 0.Paul Eggert1994-09-021-4/+8
|