mirror of
https://github.com/netsurf-browser/netsurf
synced 2025-02-02 15:46:18 +03:00
Ensure buffer is big enough for the extra character.
svn path=/trunk/netsurf/; revision=7003
This commit is contained in:
parent
bab30e4f1d
commit
28cfe681db
@ -1093,7 +1093,7 @@ void browser_window_refresh_url_bar(struct browser_window *bw, const char *url,
|
||||
|
||||
len += ((frag) ? strlen(frag) : 0);
|
||||
|
||||
url_buf = malloc(len + 2 /* '#' + '\0' */);
|
||||
url_buf = malloc(len + 3 /* '#' + '\0' */);
|
||||
if (url_buf) {
|
||||
if (frag) {
|
||||
snprintf(url_buf, len + 2, "%s#%s", url, frag);
|
||||
|
Loading…
x
Reference in New Issue
Block a user