Commit ab33eebf authored by Michael Catanzaro's avatar Michael Catanzaro

profile-migrator: Check limit before dereferencing

https://bugzilla.gnome.org/show_bug.cgi?id=783788
parent dfaf08c9
......@@ -576,7 +576,7 @@ parse_rdf_lang_tag (xmlNode *child,
locales = g_get_language_names ();
for (i = 0; locales[i] && i < *best_match; i++) {
for (i = 0; i < *best_match && locales[i]; i++) {
if (!strcmp (locales[i], this_language)) {
/* if we've already encountered a less accurate
* translation, then free it */
......
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