mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2026-11-17 18:02:09 +03:00
(xalloc_die): New function.
(main): Remove now-obsolete initialization of xalloc_fail_func.
This commit is contained in:
1 parent
8ad3011df3
commit
884a7c36eb
1 file changed
+7
-3
+7
-3
@@ -227,6 +227,13 @@ cleanup_fatal (void)
|
||||
exit (EXIT_FAILURE);
|
||||
}
|
||||
|
||||
void
|
||||
xalloc_die (void)
|
||||
{
|
||||
error (0, 0, "%s", _("memory exhausted"));
|
||||
cleanup_fatal ();
|
||||
}
|
||||
|
||||
static void
|
||||
interrupt_handler (int sig)
|
||||
{
|
||||
@@ -1328,9 +1335,6 @@ main (int argc, char **argv)
|
||||
remove_files = true;
|
||||
prefix = DEFAULT_PREFIX;
|
||||
|
||||
/* Change the way xmalloc and xrealloc fail. */
|
||||
xalloc_fail_func = cleanup;
|
||||
|
||||
while ((optc = getopt_long (argc, argv, "f:b:kn:sqz", longopts, NULL)) != -1)
|
||||
switch (optc)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user