diff options
-rw-r--r-- | content/urldb.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/content/urldb.c b/content/urldb.c index 8089e0d4e..68e39f10f 100644 --- a/content/urldb.c +++ b/content/urldb.c @@ -655,7 +655,8 @@ void urldb_write_paths(const struct path_data *parent, const char *host, *path_alloc = (len > 64) ? len : *path_alloc + 64; } - memcpy(*path + *path_used - 1, p->segment, seglen); + if (p->segment != NULL) + memcpy(*path + *path_used - 1, p->segment, seglen); if (p->children != NULL) { (*path)[*path_used + seglen - 1] = '/'; |