mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-01-12 23:46:17 +01:00
fuzzing: Use nul-terminated array introduced in previous commit
This fixes commit b2a6a9a434
. Doh.
Signed-off-by: Philip Withnall <withnall@endlessm.com>
This commit is contained in:
parent
f1a9599bcd
commit
0bf12c8bfa
@ -12,7 +12,7 @@ LLVMFuzzerTestOneInput (const unsigned char *data, size_t size)
|
||||
|
||||
/* ignore @size (g_uri_parse() doesn’t support it); ensure @data is nul-terminated */
|
||||
nul_terminated_data = (unsigned char *) g_strndup ((const gchar *) data, size);
|
||||
uri = g_uri_parse ((const gchar *) data, flags, NULL);
|
||||
uri = g_uri_parse ((const gchar *) nul_terminated_data, flags, NULL);
|
||||
g_free (nul_terminated_data);
|
||||
|
||||
if (uri == NULL)
|
||||
|
Loading…
Reference in New Issue
Block a user