Fix NULL pointer dereference with text lookups

This commit is contained in:
jp9000
2014-07-24 00:27:15 -07:00
parent c9e225d719
commit 57dcf49757

View File

@@ -409,5 +409,7 @@ void text_lookup_destroy(lookup_t lookup)
bool text_lookup_getstr(lookup_t lookup, const char *lookup_val,
const char **out)
{
return lookup_getstring(lookup_val, out, lookup->top);
if (lookup)
return lookup_getstring(lookup_val, out, lookup->top);
return false;
}