1
0
mirror of git://git.sv.gnu.org/coreutils.git synced 2026-07-26 02:30:35 +02:00
Commit Graph

18319 Commits

Author SHA1 Message Date
Jim Meyering 57c7fbf44a *** empty log message *** 2004-04-21 14:26:17 +00:00
Jim Meyering ed4778772c (main): Do not ignore SIGPIPE, as POSIX 1003.1-2001
does not allow this.  This undoes the 1996-10-24 patch.
2004-04-21 14:26:09 +00:00
Jim Meyering b55c0ce8ee *** empty log message *** 2004-04-21 12:57:46 +00:00
Jim Meyering 8ab60c41be - csplit sometimes failed to remove files when interrupted.
- csplit didn't clean up if two signals arrived nearly simultaneously.

(sigprocmask, sigset_t) [!defined SA_NOCLDSTOP]: Define.
(filename_space, prefix, suffix, digits, files_created, remove_files): Now volatile.
(caught_signals): New var.
(cleanup): Block signals while deleting all files.
(cleanup_fatal, handle_line_error, regexp_error):
Mark with ATTRIBUTE_NORETURN.
(create_output_file, close_output_file, interrupt_handler):
Block signals while changing the number of output files,
to fix some race conditions.
(delete_all_files): Do nothing if remove_files is zero.
Clear files_created.
(main): Don't mess with signals until after argument processing is done.

(main): Rewrite signal-catching code to make it
similar to other coreutils programs.  When processing signals,
block all signals that we catch, but do not block signals that we
don't catch.  Avoid problems with unsigned int warnings.

(interrupt_handler): Use void, not (obsolete) RETSIGTYPE.

(interrupt_handler) [defined SA_NOCLDSTOP]:
Use simpler "signal (sig, SIG_DFL)" rather than sigaction equivalent.
2004-04-21 12:57:33 +00:00
Jim Meyering eae1b7f862 - ls could incorrectly restore color if multiple signals
arrived nearly simultaneously.

(main): Rewrite signal-catching code to make it
similar to other coreutils programs.  When processing signals,
block all signals that we catch, but do not block signals that we
don't catch.  Avoid problems with unsigned int warnings.

(sighandler) [defined SA_NOCLDSTOP]:
Use simpler "signal (sig, SIG_DFL)" rather than sigaction equivalent.

(sighandler) [!defined SA_NOCLDSTOP]: Reset signal
handler to self, not to SIG_IGN, since SIGTSTP can be received more than once.
(main): Use SA_RESTART, as that is simpler than checking for EINTR
failures all over the place.
2004-04-21 12:51:27 +00:00
Jim Meyering 4441496397 install -s failed on System V if SIGCHLD was ignored.
Include <signal.h>.
(main) [defined SIGCHLD]: Set SIGCHLD handler to the default,
if -s is given, since System V fork+wait does not work if SIGCHLD
is ignored.
2004-04-21 12:25:18 +00:00
Jim Meyering 1119774873 *** empty log message *** 2004-04-20 18:13:54 +00:00
Jim Meyering f4e0a51788 (is_empty_dir): Clarify comment. 2004-04-20 18:13:43 +00:00
Jim Meyering d432ccecc8 (main) [!defined _POSIX_SOURCE]:
Use simpler "signal (sig, SIG_DFL)" rather than sigaction equivalent.
2004-04-20 15:10:07 +00:00
Jim Meyering 7b6892c3df (main): Rewrite signal-catching code to make it
similar to other coreutils programs.  When processing signals,
block all signals that we catch, but do not block signals that we
don't catch.  Avoid problems with unsigned int warnings.

(sighandler) [defined SA_NOCLDSTOP]:
Use simpler "signal (sig, SIG_DFL)" rather than sigaction equivalent.
2004-04-20 15:08:57 +00:00
Jim Meyering 31ef15a49f (sigill_handler, isaac_seed_machdep): Use void, not (obsolete) RETSIGTYPE. 2004-04-20 15:05:40 +00:00
Jim Meyering bb5a8d159c (main) [!defined _POSIX_SOURCE]:
Use simpler "signal (sig, SIG_IGN)" rather than sigaction equivalent.
2004-04-20 10:44:42 +00:00
Jim Meyering aa3d650a1b *** empty log message *** 2004-04-20 10:41:40 +00:00
Jim Meyering fead36411c (suspended): Change its type from int to sig_atomic_t volatile.
(first_call): Make it private to rpl_nanosleep, and have it
be zero initially as that's a bit faster.
(my_usleep): Round up fractional times instead of truncating them,
as this is the usual meaning for 'sleep'.
2004-04-20 10:41:36 +00:00
Jim Meyering 3d286f8c91 . 2004-04-20 10:18:48 +00:00
Jim Meyering 28d28cffea tweak --help output 2004-04-20 10:06:19 +00:00
Jim Meyering 74c610f8bd *** empty log message *** 2004-04-20 10:04:43 +00:00
Jim Meyering d8c64d085c (.x.1): Use help2man's new --program-name=NAME option. 2004-04-20 10:04:11 +00:00
Jim Meyering a378497e2b Accept new option: --program-name=NAME, so that we
can override the one in --version output.  This is needed solely
so that test.1 doesn't refer to `[' as the program name.
Reported by Benjamin Cutler as http://bugs.debian.org/205251.
2004-04-20 10:03:53 +00:00
Jim Meyering 9d77d864e7 *** empty log message *** 2004-04-20 10:01:51 +00:00
Jim Meyering 5976e470ac remove trailing blank 2004-04-20 09:35:17 +00:00
Jim Meyering 3d22e9548d *** empty log message *** 2004-04-20 09:34:48 +00:00
Jim Meyering d3cb92f9b8 Don't include pathmax.h; system.h already does it. 2004-04-20 09:34:43 +00:00
Jim Meyering 50469e2c80 . 2004-04-20 09:21:30 +00:00
Jim Meyering 3e7e4ac602 *** empty log message *** 2004-04-20 09:21:09 +00:00
Jim Meyering 32227588fc Change UTILS_ to gl_ in AC_DEFINE'd names.
Change utils_- and jm_-prefixed variables, too.
* host-os.m4 (gl_HOST_OS): Renamed from UTILS_HOST_OS.
2004-04-20 09:21:05 +00:00
Jim Meyering ae75db7d88 Change UTILS_ to gl_ in AC_DEFINE'd names.
Change utils_- and jm_-prefixed variables, too.
(gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
2004-04-20 09:19:52 +00:00
Jim Meyering 48f4d20c8b Reflect the renamings. 2004-04-20 09:19:27 +00:00
Jim Meyering 595b417f1d Change UTILS_ to gl_ in AC_DEFINE'd names.
Change utils_- and jm_-prefixed variables, too.

(gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
UTILS_FUNC_MKDIR_TRAILING_SLASH.
2004-04-20 09:19:09 +00:00
Jim Meyering eefa4f7f1a *** empty log message *** 2004-04-20 08:45:28 +00:00
Jim Meyering d0d80d0702 (gl_MACROS): Reflect the renaming: s/UTILS_FUNC_DIRFD/gl_FUNC_DIRFD/ 2004-04-20 08:45:24 +00:00
Jim Meyering 183dcb7d9a (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD. 2004-04-20 08:44:55 +00:00
Jim Meyering 84fc961958 *** empty log message *** 2004-04-20 08:40:41 +00:00
Jim Meyering 461c760184 Don't emit trailing blanks. 2004-04-20 08:40:38 +00:00
Jim Meyering 47d0e71e75 *** empty log message *** 2004-04-20 06:51:15 +00:00
Jim Meyering 335e3339ff (getndelim2): Upon realloc failure, don't leak memory. 2004-04-20 06:51:07 +00:00
Jim Meyering 4ef7ed5d49 *** empty log message *** 2004-04-20 06:50:46 +00:00
Jim Meyering ffccc03ad8 (cut_fields): Free buffer upon getndelim2 failure. 2004-04-20 06:50:37 +00:00
Jim Meyering 58e94308f5 . 2004-04-19 20:07:39 +00:00
Jim Meyering 5875ebea4a *** empty log message *** 2004-04-19 20:07:27 +00:00
Jim Meyering 9b10f9414f (isaac_seed_start) [AVOID_USED_UNINITIALIZED_WARNINGS]:
Initialize a buffer to avoid warnings from tools like valgrind.
2004-04-19 20:07:25 +00:00
Jim Meyering c9187f989d *** empty log message *** 2004-04-19 19:27:07 +00:00
Jim Meyering f83c840b23 . 2004-04-19 19:23:44 +00:00
Jim Meyering d15fd74064 *** empty log message *** 2004-04-19 19:01:14 +00:00
Jim Meyering 9e4222f1d9 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE, now that readutmp.c may call `free (0)'. 2004-04-19 19:01:07 +00:00
Jim Meyering 59ab879d6e *** empty log message *** 2004-04-19 19:00:49 +00:00
Jim Meyering cb5f6b9ad3 (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc failure,
don't leak memory and do call END_UTMP_ENT.
2004-04-19 18:59:52 +00:00
Jim Meyering 332853e722 . 2004-04-19 18:58:24 +00:00
Jim Meyering 4c5032e91f *** empty log message *** 2004-04-19 17:31:46 +00:00
Jim Meyering 27f330290b *** empty log message *** 2004-04-19 15:12:38 +00:00