summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
Diffstat (limited to 'gnu')
-rw-r--r--gnu/libexec/uucp/libunix/mkdirs.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/gnu/libexec/uucp/libunix/mkdirs.c b/gnu/libexec/uucp/libunix/mkdirs.c
index df4f98707f9..26307a88265 100644
--- a/gnu/libexec/uucp/libunix/mkdirs.c
+++ b/gnu/libexec/uucp/libunix/mkdirs.c
@@ -28,11 +28,6 @@ fsysdep_make_dirs (zfile, fpublic)
{
if (*z == '/' && z != zcopy)
{
- /* Some versions of uuto will send a double slash. Some
- systems will fail to create a directory ending in a
- slash. */
- if (z[-1] == '/')
- continue;
*z = '\0';
if (mkdir (zcopy, imode) != 0
&& errno != EEXIST
@@ -48,6 +43,11 @@ fsysdep_make_dirs (zfile, fpublic)
return FALSE;
}
*z = '/';
+ /* Some versions of uuto will send a double slash. Some
+ systems will fail to create a directory ending in a
+ slash. */
+ while (z[1] == '/')
+ z++;
}
}