[project @ 2006-03-16 23:30:46 by dsilvers]

Fix another assumption that freeing/dupping/whatever a NULL is safe.

svn path=/import/netsurf/; revision=2132
This commit is contained in:
Daniel Silverstone 2006-03-16 23:30:46 +00:00
parent 2a6b4b79b0
commit da16158c0a
1 changed files with 2 additions and 1 deletions

View File

@ -298,7 +298,8 @@ utf8_convert_ret utf8_convert(const char *string, size_t len,
}
/* close the last cd - we don't care if this fails */
iconv_close(last_cd.cd);
if (last_cd.cd)
iconv_close(last_cd.cd);
/* and copy the to/from/cd data into last_cd */
strncpy(last_cd.from, from, 32);