mirror of
https://github.com/jorisvink/kore
synced 2025-03-09 04:29:02 -04:00
make sure we do not dereference p if its NULL
This commit is contained in:
parent
807764614b
commit
07f2f83def
@ -110,7 +110,7 @@ kore_module_handler_find(char *domain, char *path)
|
||||
TAILQ_FOREACH(hdlr, &handlers, list) {
|
||||
if (hdlr->uri[0] != '.' && !strcmp(hdlr->uri, uri))
|
||||
return (hdlr->func);
|
||||
if (hdlr->uri[0] == '.' && !strcmp(hdlr->uri, p))
|
||||
if (p != NULL && hdlr->uri[0] == '.' && !strcmp(hdlr->uri, p))
|
||||
return (hdlr->func);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user