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
afe63135
Commit
afe63135
authored
Jun 08, 2007
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal.mysql.com:/home/bk/mysql-4.1-maint
into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-4.1-maint
parents
0c9babb0
d0c9d6cb
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
sql/sql_parse.cc
sql/sql_parse.cc
+4
-1
No files found.
sql/sql_parse.cc
View file @
afe63135
...
@@ -909,9 +909,12 @@ static int check_connection(THD *thd)
...
@@ -909,9 +909,12 @@ static int check_connection(THD *thd)
Old clients send null-terminated string as password; new clients send
Old clients send null-terminated string as password; new clients send
the size (1 byte) + string (not null-terminated). Hence in case of empty
the size (1 byte) + string (not null-terminated). Hence in case of empty
password both send '\0'.
password both send '\0'.
Cast *passwd to an unsigned char, so that it doesn't extend the sign for
*passwd > 127 and become 2**32-127 after casting to uint.
*/
*/
uint
passwd_len
=
thd
->
client_capabilities
&
CLIENT_SECURE_CONNECTION
?
uint
passwd_len
=
thd
->
client_capabilities
&
CLIENT_SECURE_CONNECTION
?
*
passwd
++
:
strlen
(
passwd
);
(
uchar
)(
*
passwd
++
)
:
strlen
(
passwd
);
db
=
thd
->
client_capabilities
&
CLIENT_CONNECT_WITH_DB
?
db
=
thd
->
client_capabilities
&
CLIENT_CONNECT_WITH_DB
?
db
+
passwd_len
+
1
:
0
;
db
+
passwd_len
+
1
:
0
;
uint
db_len
=
db
?
strlen
(
db
)
:
0
;
uint
db_len
=
db
?
strlen
(
db
)
:
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