diff options
author | Thomas White <taw@bitwiz.me.uk> | 2020-01-13 00:04:55 +0100 |
---|---|---|
committer | Thomas White <taw@bitwiz.me.uk> | 2020-01-13 00:04:55 +0100 |
commit | 7304e278ced9adee5884482bbf3223f8ba1ccfde (patch) | |
tree | 73ec0dd900c61c5737b1fa1bb6b9099c78bdacc8 | |
parent | 956d397b8d34ba79fc7486f609a22ba80216384f (diff) |
lookup_style: Check that path isn't NULL
-rw-r--r-- | libstorycode/stylesheet.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libstorycode/stylesheet.c b/libstorycode/stylesheet.c index 8fa904e..66e444c 100644 --- a/libstorycode/stylesheet.c +++ b/libstorycode/stylesheet.c @@ -168,6 +168,7 @@ static struct style *lookup_style(struct style *sty, const char *path) const char *nxt = path; assert(sty != NULL); + if ( path == NULL ) return NULL; if ( path[0] == '\0' ) return sty; for ( i=0; i<sty->n_substyles; i++ ) { |