Regex leak on error path

Don't leak the GRegex struct when g_regex_new() fails.
This commit is contained in:
Paolo Borelli 2009-04-03 00:04:39 -04:00 committed by Matthias Clasen
parent 82a5f787d6
commit e8a42bb81c

View File

@ -1199,6 +1199,8 @@ g_regex_new (const gchar *pattern,
regex->pattern,
errmsg);
g_propagate_error (error, tmp_error);
g_regex_unref (regex);
return NULL;
}
}