From 418467e32ad8617c1546870f1b24493601ca4d47 Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 26 Apr 2003 17:57:19 +0300 Subject: Fix possible memory overrun when reading broken character set files sql/mysqld.cc: Safety fix. --- mysys/charset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mysys/charset.c') diff --git a/mysys/charset.c b/mysys/charset.c index 9d9ede2b0c4..4cd32e7e3da 100644 --- a/mysys/charset.c +++ b/mysys/charset.c @@ -85,7 +85,7 @@ static my_bool get_word(struct simpleconfig_buf_st *fb, char *buf) endptr = fb->buf; } - while (!isspace(*endptr)) + while (*endptr && !isspace(*endptr)) *buf++= *endptr++; *buf=0; fb->p = endptr; -- cgit v1.2.1