Commit 92b75767 authored by Max Kellermann's avatar Max Kellermann

assert value!=NULL in fix_utf8()

We must never pass value==NULL to fix_utf(). Replace the run-time check with an assertion.
parent f99fe808
...@@ -350,7 +350,9 @@ int tag_equal(struct tag *tag1, struct tag *tag2) ...@@ -350,7 +350,9 @@ int tag_equal(struct tag *tag1, struct tag *tag2)
static inline char *fix_utf8(char *str) { static inline char *fix_utf8(char *str) {
char *temp; char *temp;
if (str != NULL && validUtf8String(str)) assert(str != NULL);
if (validUtf8String(str))
return str; return str;
DEBUG("not valid utf8 in tag: %s\n",str); DEBUG("not valid utf8 in tag: %s\n",str);
......
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