1 diff -ur tar-1.26.orig//gnu/fcntl.c tar-1.26/gnu/fcntl.c
2 --- tar-1.26.orig//gnu/fcntl.c 2011-03-12 04:14:28.000000000 -0500
3 +++ tar-1.26/gnu/fcntl.c 2011-12-10 12:13:00.000000000 -0500
9 +/* This is needed due to the conflicting version
10 + * of getdtablesize from bsdsocket.library, which
11 + * only counts the number of socket descriptors.
14 +#define getdtablesize() 256
17 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
18 /* Get declarations of the Win32 API functions. */
19 # define WIN32_LEAN_AND_MEAN
20 diff -ur tar-1.26.orig//lib/rtapelib.c tar-1.26/lib/rtapelib.c
21 --- tar-1.26.orig//lib/rtapelib.c 2010-09-14 06:06:44.000000000 -0400
22 +++ tar-1.26/lib/rtapelib.c 2011-03-12 04:50:18.000000000 -0500
25 /* If true, always consider file names to be local, even if they contain
27 -bool force_local_option;
28 +bool force_local_option = true;
37 /* FIXME: Should somewhat validate the decoding, here. */
38 if (gethostbyname (remote_host) == NULL)
39 error (EXIT_ON_EXEC_ERROR, 0, _("Cannot connect to %s: resolve failed"),
43 if (remote_user && *remote_user == '\0')
54 diff -ur tar-1.26.orig//src/misc.c tar-1.26/src/misc.c
55 --- tar-1.26.orig//src/misc.c 2011-02-16 17:12:16.000000000 -0500
56 +++ tar-1.26/src/misc.c 2011-03-12 04:50:18.000000000 -0500
64 call_arg_fatal ("fork", _("child process"));
68 page_aligned_alloc (void **ptr, size_t size)
70 - size_t alignment = getpagesize ();
71 + size_t alignment = 2048;
72 size_t size1 = size + alignment;
75 diff -ur tar-1.26.orig//src/system.c tar-1.26/src/system.c
76 --- tar-1.26.orig//src/system.c 2010-11-05 04:16:25.000000000 -0400
77 +++ tar-1.26/src/system.c 2011-03-12 04:50:18.000000000 -0500
79 const char *shell = getenv ("SHELL");
84 + if (child == (pid_t) -1)
85 + call_arg_fatal ("fork", _("child process"));
88 priv_set_restore_linkdir ();
93 - child_pid = xfork ();
94 + child_pid = vfork ();
95 + if (child_pid == (pid_t) -1)
96 + call_arg_fatal ("fork", _("child process"));
101 /* We do need a grandchild tar. */
104 - grandchild_pid = xfork ();
105 + grandchild_pid = vfork ();
106 + if (grandchild_pid == (pid_t) -1)
107 + call_arg_fatal ("fork", _("child process"));
109 if (grandchild_pid == 0)
115 - child_pid = xfork ();
116 + child_pid = vfork ();
117 + if (child_pid == (pid_t) -1)
118 + call_arg_fatal ("fork", _("child process"));
123 /* We do need a grandchild tar. */
126 - grandchild_pid = xfork ();
127 + grandchild_pid = vfork ();
128 + if (grandchild_pid == (pid_t) -1)
129 + call_arg_fatal ("fork", _("child process"));
131 if (grandchild_pid == 0)
136 pipe_handler = signal (SIGPIPE, SIG_IGN);
137 - global_pid = xfork ();
138 + global_pid = vfork ();
139 + if (global_pid == (pid_t) -1)
140 + call_arg_fatal ("fork", _("child process"));
146 saved_handler = signal (SIGPIPE, SIG_IGN);
150 + if (pid == (pid_t) -1)
151 + call_arg_fatal ("fork", _("child process"));