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
7ffcf6f6
Commit
7ffcf6f6
authored
May 28, 2003
by
bar@bar.mysql.r18.ru
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
"mysql" now sends client character set to server.
parent
7df5635f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
1 deletion
+12
-1
client/mysql.cc
client/mysql.cc
+1
-0
libmysql/libmysql.c
libmysql/libmysql.c
+2
-1
sql/sql_parse.cc
sql/sql_parse.cc
+9
-0
No files found.
client/mysql.cc
View file @
7ffcf6f6
...
...
@@ -2549,6 +2549,7 @@ sql_real_connect(char *host,char *database,char *user,char *password,
select_limit
,
max_join_size
);
mysql_options
(
&
mysql
,
MYSQL_INIT_COMMAND
,
init_command
);
}
mysql_options
(
&
mysql
,
MYSQL_SET_CHARSET_NAME
,
default_charset
);
if
(
!
mysql_real_connect
(
&
mysql
,
host
,
user
,
password
,
database
,
opt_mysql_port
,
opt_mysql_unix_port
,
connect_flag
|
CLIENT_MULTI_QUERIES
))
...
...
libmysql/libmysql.c
View file @
7ffcf6f6
...
...
@@ -2241,7 +2241,8 @@ mysql_real_connect(MYSQL *mysql,const char *host, const char *user,
const
char
*
save
=
charsets_dir
;
if
(
mysql
->
options
.
charset_dir
)
charsets_dir
=
mysql
->
options
.
charset_dir
;
mysql
->
charset
=
get_charset_by_name
(
mysql
->
options
.
charset_name
,
mysql
->
charset
=
get_charset_by_csname
(
mysql
->
options
.
charset_name
,
MY_CS_PRIMARY
,
MYF
(
MY_WME
));
charsets_dir
=
save
;
}
...
...
sql/sql_parse.cc
View file @
7ffcf6f6
...
...
@@ -664,8 +664,17 @@ check_connections(THD *thd)
thd
->
max_client_packet_length
=
uint4korr
(
net
->
read_pos
+
4
);
if
(
!
(
thd
->
variables
.
character_set_client
=
get_charset
((
uint
)
net
->
read_pos
[
8
],
MYF
(
0
))))
{
thd
->
variables
.
character_set_client
=
global_system_variables
.
character_set_client
;
thd
->
variables
.
collation_connection
=
global_system_variables
.
collation_connection
;
}
else
{
thd
->
variables
.
collation_connection
=
thd
->
variables
.
character_set_client
;
}
end
=
(
char
*
)
net
->
read_pos
+
32
;
}
else
...
...
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