diff options
Diffstat (limited to 'archive-tar.c')
-rw-r--r-- | archive-tar.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/archive-tar.c b/archive-tar.c index 0726996..8ae3012 100644 --- a/archive-tar.c +++ b/archive-tar.c @@ -9,6 +9,7 @@ #include "tar.h" #include "archive.h" #include "object-store-ll.h" +#include "strbuf.h" #include "streaming.h" #include "run-command.h" #include "write-or-die.h" @@ -364,7 +365,7 @@ static struct archiver *find_tar_filter(const char *name, size_t len) int i; for (i = 0; i < nr_tar_filters; i++) { struct archiver *ar = tar_filters[i]; - if (!strncmp(ar->name, name, len) && !ar->name[len]) + if (!xstrncmpz(ar->name, name, len)) return ar; } return NULL; |