]> granicus.if.org Git - php/commitdiff
Merge registry fix
authorZeev Suraski <zeev@php.net>
Mon, 14 Mar 2005 12:42:05 +0000 (12:42 +0000)
committerZeev Suraski <zeev@php.net>
Mon, 14 Mar 2005 12:42:05 +0000 (12:42 +0000)
win32/registry.c

index 6eda0f9fffa3be7c032e1d4b06897670057a301b..95d142cfa8b5edd251e56c7fb6063d8f25d05e04 100644 (file)
@@ -38,6 +38,9 @@ void UpdateIniFromRegistry(char *path TSRMLS_DC)
                                drive_letter = tmp_buf[0];
                                cwd++;
                        }
+                       while (*cwd == '\\' || *cwd == '/') {
+                               cwd++;
+                       }
                        path = (char *) emalloc(2+strlen(cwd)+1+strlen(orig_path)+1);
                        sprintf(path, "%c\\%s\\%s", drive_letter, cwd, orig_path);
                        efree(orig_path);