From: Eric Bollengier Date: Sun, 31 Aug 2008 17:57:29 +0000 (+0000) Subject: ebl Fix bad value for the first Last FM X-Git-Tag: Release-3.0.0~1039 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=ff0d48fb67cf65bb728770b5e3ddec732b6630d7;p=bacula%2Fbacula ebl Fix bad value for the first Last FM git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@7534 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/bacula/src/stored/vtape.c b/bacula/src/stored/vtape.c index 99e9fdd135..daeb7d9a66 100644 --- a/bacula/src/stored/vtape.c +++ b/bacula/src/stored/vtape.c @@ -961,7 +961,9 @@ int vtape::open(const char *pathname, int uflags) /* If the vtape is empty, start by writing a EOF */ if (online && !read_fm(VT_READ_EOF)) { - weof(); + lseek(fd, 0, SEEK_SET); /* rewind */ + cur_FM = next_FM = last_FM = 0; /* reset */ + weof(); /* write the first EOF */ last_file = current_file=0; }