Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
b448b622
Commit
b448b622
authored
Jan 21, 2007
by
tsmith@siva.hindu.god
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Applied innodb-4.1-ss36 and innodb-4.1-ss38 snapshots
Fixes: - Bug #24299: - Bug #25596:
parent
6e915574
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
13 deletions
+16
-13
innobase/dict/dict0dict.c
innobase/dict/dict0dict.c
+16
-13
No files found.
innobase/dict/dict0dict.c
View file @
b448b622
...
@@ -27,6 +27,9 @@ Created 1/8/1996 Heikki Tuuri
...
@@ -27,6 +27,9 @@ Created 1/8/1996 Heikki Tuuri
#include "que0que.h"
#include "que0que.h"
#include "rem0cmp.h"
#include "rem0cmp.h"
/* Implement isspace() in a locale-independent way. (Bug #24299) */
#define ib_isspace(c) ((char) (c) && strchr(" \v\f\t\r\n", c))
dict_sys_t
*
dict_sys
=
NULL
;
/* the dictionary system */
dict_sys_t
*
dict_sys
=
NULL
;
/* the dictionary system */
rw_lock_t
dict_operation_lock
;
/* table create, drop, etc. reserve
rw_lock_t
dict_operation_lock
;
/* table create, drop, etc. reserve
...
@@ -2374,7 +2377,7 @@ dict_accept(
...
@@ -2374,7 +2377,7 @@ dict_accept(
*
success
=
FALSE
;
*
success
=
FALSE
;
while
(
isspace
(
*
ptr
))
{
while
(
i
b_i
sspace
(
*
ptr
))
{
ptr
++
;
ptr
++
;
}
}
...
@@ -2419,7 +2422,7 @@ dict_scan_id(
...
@@ -2419,7 +2422,7 @@ dict_scan_id(
*
id
=
NULL
;
*
id
=
NULL
;
while
(
isspace
(
*
ptr
))
{
while
(
i
b_i
sspace
(
*
ptr
))
{
ptr
++
;
ptr
++
;
}
}
...
@@ -2450,7 +2453,7 @@ dict_scan_id(
...
@@ -2450,7 +2453,7 @@ dict_scan_id(
len
++
;
len
++
;
}
}
}
else
{
}
else
{
while
(
!
isspace
(
*
ptr
)
&&
*
ptr
!=
'('
&&
*
ptr
!=
')'
while
(
!
i
b_i
sspace
(
*
ptr
)
&&
*
ptr
!=
'('
&&
*
ptr
!=
')'
&&
(
accept_also_dot
||
*
ptr
!=
'.'
)
&&
(
accept_also_dot
||
*
ptr
!=
'.'
)
&&
*
ptr
!=
','
&&
*
ptr
!=
'\0'
)
{
&&
*
ptr
!=
','
&&
*
ptr
!=
'\0'
)
{
...
@@ -2480,12 +2483,12 @@ dict_scan_id(
...
@@ -2480,12 +2483,12 @@ dict_scan_id(
if
(
heap
&&
!
quote
)
{
if
(
heap
&&
!
quote
)
{
/* EMS MySQL Manager sometimes adds characters 0xA0 (in
/* EMS MySQL Manager sometimes adds characters 0xA0 (in
latin1, a 'non-breakable space') to the end of a table name.
latin1, a 'non-breakable space') to the end of a table name.
But isspace(0xA0) is not true, which confuses our foreign key
After the UTF-8 conversion in ha_innodb.cc, bytes 0xC2
parser. After the UTF-8 conversion in ha_innodb.cc, bytes 0xC2
and 0xA0 are at the end of the string, and ib_isspace()
and 0xA0 are at the end of the string
.
does not work for multi-byte UTF-8 characters
.
TODO: we should
lex the string using thd->charset_info, and
In MySQL 5.1 we
lex the string using thd->charset_info, and
my_isspace().
Only after that, convert id names to UTF-8
. */
my_isspace().
This workaround is not needed there
. */
b
=
(
byte
*
)(
*
id
);
b
=
(
byte
*
)(
*
id
);
id_len
=
strlen
(
b
);
id_len
=
strlen
(
b
);
...
@@ -2956,11 +2959,11 @@ loop:
...
@@ -2956,11 +2959,11 @@ loop:
ut_a
(
success
);
ut_a
(
success
);
if
(
!
isspace
(
*
ptr
)
&&
*
ptr
!=
'"'
&&
*
ptr
!=
'`'
)
{
if
(
!
i
b_i
sspace
(
*
ptr
)
&&
*
ptr
!=
'"'
&&
*
ptr
!=
'`'
)
{
goto
loop
;
goto
loop
;
}
}
while
(
isspace
(
*
ptr
))
{
while
(
i
b_i
sspace
(
*
ptr
))
{
ptr
++
;
ptr
++
;
}
}
...
@@ -2990,7 +2993,7 @@ loop:
...
@@ -2990,7 +2993,7 @@ loop:
goto
loop
;
goto
loop
;
}
}
if
(
!
isspace
(
*
ptr
))
{
if
(
!
i
b_i
sspace
(
*
ptr
))
{
goto
loop
;
goto
loop
;
}
}
...
@@ -3078,7 +3081,7 @@ col_loop1:
...
@@ -3078,7 +3081,7 @@ col_loop1:
}
}
ptr
=
dict_accept
(
ptr
,
"REFERENCES"
,
&
success
);
ptr
=
dict_accept
(
ptr
,
"REFERENCES"
,
&
success
);
if
(
!
success
||
!
isspace
(
*
ptr
))
{
if
(
!
success
||
!
i
b_i
sspace
(
*
ptr
))
{
dict_foreign_report_syntax_err
(
name
,
start_of_latest_foreign
,
dict_foreign_report_syntax_err
(
name
,
start_of_latest_foreign
,
ptr
);
ptr
);
return
(
DB_CANNOT_ADD_CONSTRAINT
);
return
(
DB_CANNOT_ADD_CONSTRAINT
);
...
@@ -3461,7 +3464,7 @@ loop:
...
@@ -3461,7 +3464,7 @@ loop:
ptr
=
dict_accept
(
ptr
,
"DROP"
,
&
success
);
ptr
=
dict_accept
(
ptr
,
"DROP"
,
&
success
);
if
(
!
isspace
(
*
ptr
))
{
if
(
!
i
b_i
sspace
(
*
ptr
))
{
goto
loop
;
goto
loop
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment