1
0
mirror of https://github.com/irssi/irssi.git synced 2024-11-03 04:27:19 -05:00

mkpath() crashed with paths that didn't start with /

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@867 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2000-11-25 20:54:24 +00:00 committed by cras
parent 45c9838141
commit 2e96f68445

View File

@ -394,6 +394,11 @@ int mkpath(const char *path, int mode)
g_return_val_if_fail(path != NULL, -1);
p = g_path_skip_root((char *) path);
if (p == NULL) {
/* not a full path, maybe not what we wanted
but continue anyway.. */
p = path;
}
for (;;) {
if (*p != G_DIR_SEPARATOR && *p != '\0') {
p++;