Skip to content

Commit d832869

Browse files
author
Kailasnath Nagarkar
committed
Bug #25447551: HANDLE_FATAL_SIGNAL (SIG=11) IN
FT_BOOLEAN_CHECK_SYNTAX_STRING ISSUE: my_isalnum macro used for checking if character is alphanumeric dereferences uninitialized pointer in default character set structure resulting in server exiting abnormally. FIX: Used standard isalnum function instead of macro my_isalnum.
1 parent 8ea859d commit d832869

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

storage/myisam/ft_parser.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
1+
/* Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
22
33
This program is free software; you can redistribute it and/or modify
44
it under the terms of the GNU General Public License as published by
@@ -16,6 +16,7 @@
1616
/* Written by Sergei A. Golubchik, who has a shared copyright to this code */
1717

1818
#include "ftdefs.h"
19+
#include "ctype.h"
1920

2021
typedef struct st_ft_docstat {
2122
FT_WORD *list;
@@ -89,7 +90,7 @@ my_bool ft_boolean_check_syntax_string(const uchar *str)
8990
for (i=0; i<sizeof(DEFAULT_FTB_SYNTAX); i++)
9091
{
9192
/* limiting to 7-bit ascii only */
92-
if ((unsigned char)(str[i]) > 127 || my_isalnum(default_charset_info, str[i]))
93+
if ((unsigned char)(str[i]) > 127 || isalnum(str[i]))
9394
return 1;
9495
for (j=0; j<i; j++)
9596
if (str[i] == str[j] && (i != 11 || j != 10))

0 commit comments

Comments
 (0)