X-Git-Url: https://git.wh0rd.org/?p=dump.git;a=blobdiff_plain;f=dump%2Foptr.c;h=73347fabdc2dc743c8d9373fc16da88fc2ca2ca4;hp=cd98e6664d36ba963f6fbd41c6001fbcd88b5b71;hb=11856e771fadee7ddb9b5a613c91f562bf363da7;hpb=e084ba00f03da98a6d260b0b3856aee2dfbb4c58 diff --git a/dump/optr.c b/dump/optr.c index cd98e66..73347fa 100644 --- a/dump/optr.c +++ b/dump/optr.c @@ -2,8 +2,8 @@ * Ported to Linux's Second Extended File System as part of the * dump and restore backup suit * Remy Card , 1994-1997 - * Stelian Pop , 1999-2000 - * Stelian Pop - Alcôve , 2000 + * Stelian Pop , 1999-2000 + * Stelian Pop - Alcôve , 2000-2002 */ /*- @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: optr.c,v 1.26 2001/08/16 09:37:59 stelian Exp $"; + "$Id: optr.c,v 1.29 2002/01/16 09:32:14 stelian Exp $"; #endif /* not lint */ #include @@ -70,7 +70,6 @@ static const char rcsid[] = #include #include #include -#include #endif #include "dump.h" @@ -540,7 +539,7 @@ fstabsearchdir(const char *key, char *directory) for (pf = table; pf != NULL; pf = pf->pf_next) { fs = pf->pf_fstab; if (strlen(fs->fs_file) > size && - strlen(key) > strlen(fs->fs_file) + 1 && + strlen(key) > strlen(fs->fs_file) && strncmp(fs->fs_file, key, strlen(fs->fs_file)) == 0 && (key[strlen(fs->fs_file)] == '/' || fs->fs_file[strlen(fs->fs_file) - 1] == '/')) {