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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
ee0475bf
Commit
ee0475bf
authored
Mar 29, 2007
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Code layout fix for bug N 27079
Thanks to Gluh for suggestion.
parent
6370f622
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
17 deletions
+16
-17
strings/ctype-uca.c
strings/ctype-uca.c
+16
-17
No files found.
strings/ctype-uca.c
View file @
ee0475bf
...
...
@@ -6777,25 +6777,24 @@ static void my_uca_scanner_init_ucs2(my_uca_scanner *scanner,
scanner
->
uca_length
=
cs
->
sort_order
;
scanner
->
uca_weight
=
cs
->
sort_order_big
;
scanner
->
contractions
=
cs
->
contractions
;
return
;
}
else
{
/*
Sometimes this function is called with
str=NULL and length=0, which should be
considered as an empty string.
The above initialization is unsafe for such cases,
because scanner->send is initialized to (NULL-2), which is 0xFFFFFFFE.
Then we fall into an endless loop in my_uca_scanner_next_ucs2().
/*
Sometimes this function is called with
str=NULL and length=0, which should be
considered as an empty string.
The above initialization is unsafe for such cases,
because scanner->send is initialized to (NULL-2), which is 0xFFFFFFFE.
Then we fall into an endless loop in my_uca_scanner_next_ucs2().
Do special initialization for the case when length=0.
Initialize scanner->sbeg to an address greater than scanner->send.
Next call of my_uca_scanner_next_ucs2() will correctly return with -1.
*/
scanner
->
sbeg
=
(
uchar
*
)
&
nochar
[
1
];
scanner
->
send
=
(
uchar
*
)
&
nochar
[
0
];
}
Do special initialization for the case when length=0.
Initialize scanner->sbeg to an address greater than scanner->send.
Next call of my_uca_scanner_next_ucs2() will correctly return with -1.
*/
scanner
->
sbeg
=
(
uchar
*
)
&
nochar
[
1
];
scanner
->
send
=
(
uchar
*
)
&
nochar
[
0
];
}
...
...
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