mirror of
https://github.com/netsurf-browser/netsurf
synced 2025-02-05 00:54:06 +03:00
Don't call memcpy when p->segment is NULL
svn path=/trunk/netsurf/; revision=9687
This commit is contained in:
parent
51d545772c
commit
81c1b0e0df
@ -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] = '/';
|
||||
|
Loading…
x
Reference in New Issue
Block a user