1.1 --- a/util.c Sat Apr 05 01:15:04 2008 -0400
1.2 +++ b/util.c Mon Jun 09 14:38:58 2008 -0400
1.3 @@ -15,9 +15,9 @@
1.4 const char *slash, *next;
1.5 struct stat buf;
1.6
1.7 - /* Create all sub-directories in dir and then create name. We
1.8 - * know root exists and is a dir, root does not end in a '/',
1.9 - * and path has a leading '/'. */
1.10 + /* Create all sub-directories in dir. We know root exists and
1.11 + * is a dir, root does not end in a '/', and path has a
1.12 + * leading '/'. */
1.13
1.14 strcpy(buffer, root);
1.15 p = buffer + strlen(buffer);
1.16 @@ -25,7 +25,7 @@
1.17 for (slash = path; *slash != '\0'; slash = next) {
1.18 next = strchr(slash + 1, '/');
1.19 if (next == NULL)
1.20 - next = slash + strlen(slash);
1.21 + break;
1.22
1.23 memcpy(p, slash, next - slash);
1.24 p += next - slash;