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
059b1e56
Commit
059b1e56
authored
Jun 05, 2003
by
monty@narttu.mysql.fi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
After merge fixes
parent
0303cd57
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
31 additions
and
29 deletions
+31
-29
include/sql_common.h
include/sql_common.h
+1
-0
mysql-test/r/repair_part1.result
mysql-test/r/repair_part1.result
+0
-0
mysql-test/t/repair_part1.test
mysql-test/t/repair_part1.test
+0
-0
scripts/Makefile.am
scripts/Makefile.am
+3
-2
sql-common/client.c
sql-common/client.c
+27
-27
No files found.
include/sql_common.h
View file @
059b1e56
...
...
@@ -16,6 +16,7 @@
extern
const
char
*
unknown_sqlstate
;
extern
const
char
*
not_error_sqlstate
;
#ifdef __cplusplus
extern
"C"
{
...
...
mysql-test/r/repair.result
→
mysql-test/r/repair
_part1
.result
View file @
059b1e56
File moved
mysql-test/t/repair.test
→
mysql-test/t/repair
_part1
.test
View file @
059b1e56
File moved
scripts/Makefile.am
View file @
059b1e56
...
...
@@ -33,7 +33,6 @@ bin_SCRIPTS = @server_scripts@ \
mysql_explain_log
\
mysql_tableinfo
\
mysqld_multi
\
fill_help_tables
\
mysql_create_system_tables
EXTRA_SCRIPTS
=
make_binary_distribution.sh
\
...
...
@@ -140,5 +139,7 @@ SUFFIXES = .sh
# Don't update the files from bitkeeper
%
::
SCCS/s.%
all
:
make_win_src_distribution make_binary_distribution
all
:
fill_help_tables.sql
make_win_src_distribution make_binary_distribution
fill_help_tables.sql
:
fill_help_tables ../Docs/manual.texi
./fill_help_tables < ../Docs/manual.texi
>
fill_help_tables.sql
sql-common/client.c
View file @
059b1e56
...
...
@@ -99,7 +99,8 @@
#include "client_settings.h"
#include <sql_common.h>
const
char
*
unknown_sqlstate
=
"000000"
;
const
char
*
unknown_sqlstate
=
"HY0000"
;
const
char
*
not_error_sqlstate
=
"00000"
;
#ifdef MYSQL_CLIENT
extern
my_bool
stmt_close
(
MYSQL_STMT
*
stmt
,
my_bool
skip_list
);
...
...
@@ -369,32 +370,30 @@ HANDLE create_shared_memory(MYSQL *mysql,NET *net, uint connect_timeout)
error_allow
=
CR_SHARED_MEMORY_CONNECT_MAP_ERROR
;
goto
err
;
}
/*
Send to server request of connection
*/
/* Send to server request of connection */
if
(
!
SetEvent
(
event_connect_request
))
{
error_allow
=
CR_SHARED_MEMORY_CONNECT_SET_ERROR
;
goto
err
;
}
/*
Wait of answer from server
*/
/* Wait of answer from server */
if
(
WaitForSingleObject
(
event_connect_answer
,
connect_timeout
*
1000
)
!=
WAIT_OBJECT_0
)
{
error_allow
=
CR_SHARED_MEMORY_CONNECT_ABANDODED_ERROR
;
goto
err
;
}
/*
Get number of connection
*/
/* Get number of connection */
connect_number
=
uint4korr
(
handle_connect_map
);
/*WAX2*/
p
=
int2str
(
connect_number
,
connect_number_char
,
10
);
/*
The name of event and file-mapping events create agree next rule:
shared_memory_base_name+unique_part+number_of_connection
Where:
shared_memory_base_name is uniquel value for each server
unique_part is uniquel value for each object (events and file-mapping)
...
...
@@ -506,7 +505,7 @@ net_safe_read(MYSQL *mysql)
{
NET
*
net
=
&
mysql
->
net
;
ulong
len
=
0
;
init_sigpipe_variables
init_sigpipe_variables
;
/* Don't give sigpipe errors if the client doesn't want them */
set_sigpipe
(
mysql
);
...
...
@@ -571,7 +570,7 @@ advanced_command(MYSQL *mysql, enum enum_server_command command,
{
NET
*
net
=
&
mysql
->
net
;
my_bool
result
=
1
;
init_sigpipe_variables
init_sigpipe_variables
;
/* Don't give sigpipe errors if the client doesn't want them */
set_sigpipe
(
mysql
);
...
...
@@ -589,8 +588,8 @@ advanced_command(MYSQL *mysql, enum enum_server_command command,
}
net
->
last_error
[
0
]
=
0
;
net
->
last_errno
=
0
;
strmov
(
net
->
sqlstate
,
unknown
_sqlstate
);
net
->
last_errno
=
0
;
strmov
(
net
->
sqlstate
,
not_error
_sqlstate
);
mysql
->
net
.
report_error
=
0
;
mysql
->
info
=
0
;
mysql
->
affected_rows
=
~
(
my_ulonglong
)
0
;
...
...
@@ -624,7 +623,7 @@ advanced_command(MYSQL *mysql, enum enum_server_command command,
if
(
!
skip_check
)
result
=
((
mysql
->
packet_length
=
net_safe_read
(
mysql
))
==
packet_error
?
1
:
0
);
end:
end:
reset_sigpipe
(
mysql
);
return
result
;
}
...
...
@@ -665,7 +664,7 @@ void end_server(MYSQL *mysql)
DBUG_ENTER
(
"end_server"
);
if
(
mysql
->
net
.
vio
!=
0
)
{
init_sigpipe_variables
init_sigpipe_variables
;
DBUG_PRINT
(
"info"
,(
"Net: %s"
,
vio_description
(
mysql
->
net
.
vio
)));
set_sigpipe
(
mysql
);
vio_delete
(
mysql
->
net
.
vio
);
...
...
@@ -1457,7 +1456,7 @@ mysql_real_connect(MYSQL *mysql,const char *host, const char *user,
#ifdef HAVE_SYS_UN_H
struct
sockaddr_un
UNIXaddr
;
#endif
init_sigpipe_variables
init_sigpipe_variables
;
DBUG_ENTER
(
"mysql_real_connect"
);
LINT_INIT
(
host_info
);
...
...
@@ -1561,7 +1560,7 @@ mysql_real_connect(MYSQL *mysql,const char *host, const char *user,
net
->
vio
=
vio_new
(
sock
,
VIO_TYPE_SOCKET
,
TRUE
);
bzero
((
char
*
)
&
UNIXaddr
,
sizeof
(
UNIXaddr
));
UNIXaddr
.
sun_family
=
AF_UNIX
;
strm
ov
(
UNIXaddr
.
sun_path
,
unix_socket
);
strm
ake
(
UNIXaddr
.
sun_path
,
unix_socket
,
sizeof
(
UNIXaddr
.
sun_path
)
-
1
);
if
(
my_connect
(
sock
,(
struct
sockaddr
*
)
&
UNIXaddr
,
sizeof
(
UNIXaddr
),
mysql
->
options
.
connect_timeout
))
{
...
...
@@ -2090,13 +2089,14 @@ static void mysql_fix_pointers(MYSQL* mysql, MYSQL* old_mysql)
#endif
/*MYSQL_CLIENT*/
}
my_bool
mysql_reconnect
(
MYSQL
*
mysql
)
{
MYSQL
tmp_mysql
;
DBUG_ENTER
(
"mysql_reconnect"
);
if
(
!
mysql
->
reconnect
||
(
mysql
->
server_status
&
SERVER_STATUS_IN_TRANS
)
||
!
mysql
->
host_info
)
if
(
!
mysql
->
reconnect
||
(
mysql
->
server_status
&
SERVER_STATUS_IN_TRANS
)
||
!
mysql
->
host_info
)
{
/* Allow reconnect next time */
mysql
->
server_status
&=
~
SERVER_STATUS_IN_TRANS
;
...
...
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