From 05e782ddd3dc58245c889529bb8aeeaddf24bf71 Mon Sep 17 00:00:00 2001 From: Matt Kraai Date: Thu, 1 Feb 2001 16:49:30 +0000 Subject: Fix wget error message and add (and use) chomp library function. --- archival/tar.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'archival/tar.c') diff --git a/archival/tar.c b/archival/tar.c index 60744e8db..fb0fcc614 100644 --- a/archival/tar.c +++ b/archival/tar.c @@ -274,8 +274,7 @@ extern int tar_main(int argc, char **argv) while (fgets(file, sizeof(file), fileList) != NULL) { excludeList = xrealloc(excludeList, sizeof(char *) * (excludeListSize+2)); - if (file[strlen(file)-1] == '\n') - file[strlen(file)-1] = '\0'; + chomp(file); excludeList[excludeListSize] = xstrdup(file); /* Tack a NULL onto the end of the list */ excludeList[++excludeListSize] = NULL; -- cgit v1.2.3