]> git.wh0rd.org - dump.git/commitdiff
Discard newline when reading the tape path entered by the operator in restore.
authorStelian Pop <stelian@popies.net>
Wed, 18 Jul 2001 11:46:31 +0000 (11:46 +0000)
committerStelian Pop <stelian@popies.net>
Wed, 18 Jul 2001 11:46:31 +0000 (11:46 +0000)
CHANGES
restore/tape.c

diff --git a/CHANGES b/CHANGES
index a46e316cc210a8954e48c7ee789dcb2ffdd10f98..2565decb6dcdd5d97f0a707dba84cc1a0774a491 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,4 @@
-$Id: CHANGES,v 1.120 2001/07/18 09:50:48 stelian Exp $
+$Id: CHANGES,v 1.121 2001/07/18 11:46:31 stelian Exp $
 
 Changes between versions 0.4b22 and 0.4b23 (released ????????????)
 ==================================================================
 
 Changes between versions 0.4b22 and 0.4b23 (released ????????????)
 ==================================================================
@@ -26,6 +26,9 @@ Changes between versions 0.4b22 and 0.4b23 (released ????????????)
        Patch contributed by Helmut Jarausch 
        <jarausch@igpm.rwth-aachen.de>.
 
        Patch contributed by Helmut Jarausch 
        <jarausch@igpm.rwth-aachen.de>.
 
+7.     Fixed a bug in reading the operator typed file/tape path for
+       the next volume in restore.
+
 Changes between versions 0.4b21 and 0.4b22 (released May 12, 2001)
 ==================================================================
 
 Changes between versions 0.4b21 and 0.4b22 (released May 12, 2001)
 ==================================================================
 
index ee5c72fc35392003c72bd8e560219afc38a4ed1b..f7a8a10211379408d6e58d4b5d2f5668b911fd78 100644 (file)
@@ -46,7 +46,7 @@
 
 #ifndef lint
 static const char rcsid[] =
 
 #ifndef lint
 static const char rcsid[] =
-       "$Id: tape.c,v 1.40 2001/06/18 10:58:28 stelian Exp $";
+       "$Id: tape.c,v 1.41 2001/07/18 11:46:31 stelian Exp $";
 #endif /* not lint */
 
 #include <config.h>
 #endif /* not lint */
 
 #include <config.h>
@@ -452,8 +452,11 @@ again:
                        return;
                }
                if (buf[0] != '\n') {
                        return;
                }
                if (buf[0] != '\n') {
+                       char *pos;
                        (void) strncpy(magtape, buf, sizeof(magtape));
                        magtape[sizeof(magtape) - 1] = '\0';
                        (void) strncpy(magtape, buf, sizeof(magtape));
                        magtape[sizeof(magtape) - 1] = '\0';
+                       if ((pos = strchr(magtape, '\n'))) 
+                               magtape[pos - magtape] = '\0';
                }
        }
 #ifdef RRESTORE
                }
        }
 #ifdef RRESTORE