Handle mp_msg_charset == NULL correctly in filename_recode.

Patch by Vladimir Voroshilov - voroshil gmail com


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@22024 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2007-01-27 10:11:40 +00:00
parent 70e10c7436
commit b642c2280a
1 changed files with 2 additions and 1 deletions

View File

@ -48,7 +48,8 @@ const char* filename_recode(const char* filename)
static char recoded_filename[MSGSIZE_MAX];
size_t filename_len, max_path;
char* precoded;
if (!strcasecmp(mp_msg_charset, MSG_CHARSET) ||
if (!mp_msg_charset ||
!strcasecmp(mp_msg_charset, MSG_CHARSET) ||
!strcasecmp(mp_msg_charset, "noconv"))
return filename;
if (inv_msgiconv == (iconv_t)(-1)) {