Remove tar_unzip_init() not needed any more, uses gz_open instead
authorGlenn L McGrath <bug1@ihug.co.nz>
Wed, 28 Mar 2001 07:31:37 +0000 (07:31 -0000)
committerGlenn L McGrath <bug1@ihug.co.nz>
Wed, 28 Mar 2001 07:31:37 +0000 (07:31 -0000)
archival/tar.c
tar.c

index 46321de..ef61153 100644 (file)
@@ -149,43 +149,6 @@ static int writeTarFile(const char* tarName, int verboseFlag, char **argv,
                char** excludeList);
 #endif
 
-#ifdef BB_FEATURE_TAR_GZIP
-/* Signal handler for when child gzip process dies...  */
-static void child_died()
-{
-       fflush(stdout);
-       fflush(stderr);
-       exit(EXIT_FAILURE);
-}
-
-extern int tar_unzip_init(int tarFd)
-{
-       int child_pid;
-       static int unzip_pipe[2];
-       /* Cope if child dies... Otherwise we block forever in read()... */
-       signal(SIGCHLD, child_died);
-
-       if (pipe(unzip_pipe)!=0)
-               error_msg_and_die("pipe error");
-
-       if ( (child_pid = fork()) == -1)
-               error_msg_and_die("fork failure");
-
-       if (child_pid==0) {
-               /* child process */
-               close(unzip_pipe[0]);
-//             gunzip_init();
-               unzip(tarFd, unzip_pipe[1]);
-               exit(EXIT_SUCCESS);
-       }
-       else {
-               /* return fd of uncompressed data to parent process */
-               close(unzip_pipe[1]);
-               return(unzip_pipe[0]);
-       }
-}
-#endif
-
 #if defined BB_FEATURE_TAR_EXCLUDE
 static struct option longopts[] = {
        { "exclude", 1, NULL, 'e' },
diff --git a/tar.c b/tar.c
index 46321de..ef61153 100644 (file)
--- a/tar.c
+++ b/tar.c
@@ -149,43 +149,6 @@ static int writeTarFile(const char* tarName, int verboseFlag, char **argv,
                char** excludeList);
 #endif
 
-#ifdef BB_FEATURE_TAR_GZIP
-/* Signal handler for when child gzip process dies...  */
-static void child_died()
-{
-       fflush(stdout);
-       fflush(stderr);
-       exit(EXIT_FAILURE);
-}
-
-extern int tar_unzip_init(int tarFd)
-{
-       int child_pid;
-       static int unzip_pipe[2];
-       /* Cope if child dies... Otherwise we block forever in read()... */
-       signal(SIGCHLD, child_died);
-
-       if (pipe(unzip_pipe)!=0)
-               error_msg_and_die("pipe error");
-
-       if ( (child_pid = fork()) == -1)
-               error_msg_and_die("fork failure");
-
-       if (child_pid==0) {
-               /* child process */
-               close(unzip_pipe[0]);
-//             gunzip_init();
-               unzip(tarFd, unzip_pipe[1]);
-               exit(EXIT_SUCCESS);
-       }
-       else {
-               /* return fd of uncompressed data to parent process */
-               close(unzip_pipe[1]);
-               return(unzip_pipe[0]);
-       }
-}
-#endif
-
 #if defined BB_FEATURE_TAR_EXCLUDE
 static struct option longopts[] = {
        { "exclude", 1, NULL, 'e' },