From 6c8045d4698240bc20639c4f9631735bbed90fea Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 12 Jan 2004 14:31:04 +0400 Subject: [PATCH] charset.c: Fixed: client crashed when there are no Index.xml file. mysys/charset.c: Fixed: client crashed when there are no Index.xml file. --- mysys/charset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mysys/charset.c b/mysys/charset.c index f8c8237c88b..b911f29627c 100644 --- a/mysys/charset.c +++ b/mysys/charset.c @@ -540,7 +540,7 @@ static CHARSET_INFO *get_internal_charset(uint cs_number, myf flags) strxmov(get_charsets_dir(buf), cs->csname, ".xml", NullS); my_read_charset_file(buf,flags); } - cs= (cs->state & MY_CS_AVAILABLE) ? cs : NULL; + cs= (cs && cs->state & MY_CS_AVAILABLE) ? cs : NULL; pthread_mutex_unlock(&THR_LOCK_charset); return cs; }