diff options
author | Max Kellermann <max@duempel.org> | 2008-08-29 09:38:56 +0200 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2008-09-02 00:20:12 -0700 |
commit | e3805dafb34a6fb3ae0421bd0414ee7fd27e2106 (patch) | |
tree | d7815df582ea7db2a1398746b452c474a1d8fb5a | |
parent | bbafa24ba65878780101191b9313e9e70208937e (diff) | |
download | mpd-e3805dafb34a6fb3ae0421bd0414ee7fd27e2106.tar.gz mpd-e3805dafb34a6fb3ae0421bd0414ee7fd27e2106.tar.xz mpd-e3805dafb34a6fb3ae0421bd0414ee7fd27e2106.zip |
assert value!=NULL in fix_utf8()
We must never pass value==NULL to fix_utf(). Replace the run-time
check with an assertion.
Diffstat (limited to '')
-rw-r--r-- | src/tag.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -350,7 +350,9 @@ int tag_equal(struct mpd_tag *tag1, struct mpd_tag *tag2) static inline char *fix_utf8(char *str) { char *temp; - if (str != NULL && validUtf8String(str)) + assert(str != NULL); + + if (validUtf8String(str)) return str; DEBUG("not valid utf8 in tag: %s\n",str); |