fixed crash with multitargets

This commit is contained in:
Axel Kittenberger 2008-12-25 11:45:41 +00:00
parent 4133489f2e
commit 9767279d65
1 changed files with 1 additions and 1 deletions

View File

@ -542,7 +542,7 @@ void dir_conf_add_target(struct dir_conf * dir_conf, char *target)
target_n++;
}
dir_conf->targets = s_realloc(dir_conf->targets, (target_n + 1) * sizeof(char *));
dir_conf->targets = s_realloc(dir_conf->targets, (target_n + 2) * sizeof(char *));
dir_conf->targets[target_n] = s_strdup(target);
dir_conf->targets[target_n + 1] = NULL;
}