core: check that "chars" argument is not NULL in function string_strip

v2.8-utf8proc
Sébastien Helleu 2014-07-05 10:05:35 +02:00
parent 60c7696353
commit e75fef58c4
1 changed files with 1 additions and 1 deletions

View File

@ -560,7 +560,7 @@ string_strip (const char *string, int left, int right, const char *chars)
if (!string)
return NULL;
if (!string[0])
if (!string[0] || !chars)
return strdup (string);
ptr_start = string;