Commit fec38762 authored by Philip Withnall's avatar Philip Withnall
Browse files

gdate: Use string length when validating UTF-8

Makes the validation a tiny bit faster.
Signed-off-by: Philip Withnall's avatarPhilip Withnall <>
parent 15634d64
......@@ -1243,7 +1243,7 @@ g_date_set_parse (GDate *d,
/* The input has to be valid UTF-8. */
if (!g_utf8_validate (str, -1, NULL))
if (!g_utf8_validate_len (str, str_len, NULL))
G_LOCK (g_date_global);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment