]> Dogcows Code - chaz/tar/commitdiff
Bugfix.
authorSergey Poznyakoff <gray@gnu.org.ua>
Mon, 17 May 2010 17:22:16 +0000 (20:22 +0300)
committerSergey Poznyakoff <gray@gnu.org.ua>
Mon, 17 May 2010 17:22:16 +0000 (20:22 +0300)
* src/incremen.c (make_directory): Retain the slash if it is the
only character in a filename.

src/incremen.c

index dc880cd88ce32f27d00dea401d3d98309346a7b6..0d0b4ff498818409e056f1ed134afe2014f1f3d0 100644 (file)
@@ -258,7 +258,7 @@ make_directory (const char *name, char *caname)
   directory->dump = directory->idump = NULL;
   directory->orig = NULL;
   directory->flags = false;
-  if (namelen && ISSLASH (name[namelen - 1]))
+  if (namelen > 1 && ISSLASH (name[namelen - 1]))
     namelen--;
   directory->name = xmalloc (namelen + 1);
   memcpy (directory->name, name, namelen);
This page took 0.023761 seconds and 4 git commands to generate.