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
51af6729
Commit
51af6729
authored
Jan 25, 2010
by
Mats Kindahl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Patch to eliminate warnings in mysql-next-mr-bugteam.
parent
8976595d
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
25 additions
and
25 deletions
+25
-25
sql/repl_failsafe.cc
sql/repl_failsafe.cc
+1
-1
sql/repl_failsafe.h
sql/repl_failsafe.h
+1
-1
sql/rpl_injector.cc
sql/rpl_injector.cc
+6
-6
sql/rpl_mi.cc
sql/rpl_mi.cc
+2
-2
sql/slave.cc
sql/slave.cc
+6
-6
sql/sql_class.cc
sql/sql_class.cc
+3
-3
sql/sql_db.cc
sql/sql_db.cc
+1
-1
sql/sql_parse.cc
sql/sql_parse.cc
+1
-1
sql/sql_repl.cc
sql/sql_repl.cc
+2
-2
sql/sql_table.cc
sql/sql_table.cc
+1
-1
sql/sys_vars.cc
sql/sys_vars.cc
+1
-1
No files found.
sql/repl_failsafe.cc
View file @
51af6729
...
@@ -38,7 +38,7 @@
...
@@ -38,7 +38,7 @@
#define SLAVE_ERRMSG_SIZE (FN_REFLEN+64)
#define SLAVE_ERRMSG_SIZE (FN_REFLEN+64)
uint
rpl_status
=
RPL_NULL
;
RPL_STATUS
rpl_status
=
RPL_NULL
;
mysql_mutex_t
LOCK_rpl_status
;
mysql_mutex_t
LOCK_rpl_status
;
mysql_cond_t
COND_rpl_status
;
mysql_cond_t
COND_rpl_status
;
HASH
slave_list
;
HASH
slave_list
;
...
...
sql/repl_failsafe.h
View file @
51af6729
...
@@ -26,7 +26,7 @@ typedef enum {RPL_AUTH_MASTER=0,RPL_IDLE_SLAVE,RPL_ACTIVE_SLAVE,
...
@@ -26,7 +26,7 @@ typedef enum {RPL_AUTH_MASTER=0,RPL_IDLE_SLAVE,RPL_ACTIVE_SLAVE,
RPL_LOST_SOLDIER
,
RPL_TROOP_SOLDIER
,
RPL_LOST_SOLDIER
,
RPL_TROOP_SOLDIER
,
RPL_RECOVERY_CAPTAIN
,
RPL_NULL
/* inactive */
,
RPL_RECOVERY_CAPTAIN
,
RPL_NULL
/* inactive */
,
RPL_ANY
/* wild card used by change_rpl_status */
}
RPL_STATUS
;
RPL_ANY
/* wild card used by change_rpl_status */
}
RPL_STATUS
;
extern
uint
rpl_status
;
extern
RPL_STATUS
rpl_status
;
extern
mysql_mutex_t
LOCK_rpl_status
;
extern
mysql_mutex_t
LOCK_rpl_status
;
extern
mysql_cond_t
COND_rpl_status
;
extern
mysql_cond_t
COND_rpl_status
;
...
...
sql/rpl_injector.cc
View file @
51af6729
...
@@ -112,8 +112,8 @@ int injector::transaction::write_row (server_id_type sid, table tbl,
...
@@ -112,8 +112,8 @@ int injector::transaction::write_row (server_id_type sid, table tbl,
{
{
DBUG_ENTER
(
"injector::transaction::write_row(...)"
);
DBUG_ENTER
(
"injector::transaction::write_row(...)"
);
int
error
=
0
;
int
error
=
check_state
(
ROW_STATE
)
;
if
(
error
=
check_state
(
ROW_STATE
)
)
if
(
error
)
DBUG_RETURN
(
error
);
DBUG_RETURN
(
error
);
server_id_type
save_id
=
m_thd
->
server_id
;
server_id_type
save_id
=
m_thd
->
server_id
;
...
@@ -131,8 +131,8 @@ int injector::transaction::delete_row(server_id_type sid, table tbl,
...
@@ -131,8 +131,8 @@ int injector::transaction::delete_row(server_id_type sid, table tbl,
{
{
DBUG_ENTER
(
"injector::transaction::delete_row(...)"
);
DBUG_ENTER
(
"injector::transaction::delete_row(...)"
);
int
error
=
0
;
int
error
=
check_state
(
ROW_STATE
)
;
if
(
error
=
check_state
(
ROW_STATE
)
)
if
(
error
)
DBUG_RETURN
(
error
);
DBUG_RETURN
(
error
);
server_id_type
save_id
=
m_thd
->
server_id
;
server_id_type
save_id
=
m_thd
->
server_id
;
...
@@ -150,8 +150,8 @@ int injector::transaction::update_row(server_id_type sid, table tbl,
...
@@ -150,8 +150,8 @@ int injector::transaction::update_row(server_id_type sid, table tbl,
{
{
DBUG_ENTER
(
"injector::transaction::update_row(...)"
);
DBUG_ENTER
(
"injector::transaction::update_row(...)"
);
int
error
=
0
;
int
error
=
check_state
(
ROW_STATE
)
;
if
(
error
=
check_state
(
ROW_STATE
)
)
if
(
error
)
DBUG_RETURN
(
error
);
DBUG_RETURN
(
error
);
server_id_type
save_id
=
m_thd
->
server_id
;
server_id_type
save_id
=
m_thd
->
server_id
;
...
...
sql/rpl_mi.cc
View file @
51af6729
...
@@ -33,8 +33,8 @@ int init_dynarray_intvar_from_file(DYNAMIC_ARRAY* arr, IO_CACHE* f);
...
@@ -33,8 +33,8 @@ int init_dynarray_intvar_from_file(DYNAMIC_ARRAY* arr, IO_CACHE* f);
Master_info
::
Master_info
(
bool
is_slave_recovery
)
Master_info
::
Master_info
(
bool
is_slave_recovery
)
:
Slave_reporting_capability
(
"I/O"
),
:
Slave_reporting_capability
(
"I/O"
),
ssl
(
0
),
ssl_verify_server_cert
(
0
),
fd
(
-
1
),
io_thd
(
0
),
ssl
(
0
),
ssl_verify_server_cert
(
0
),
fd
(
-
1
),
io_thd
(
0
),
port
(
MYSQL_PORT
),
connect_retry
(
DEFAULT_CONNECT_RETRY
),
inited
(
0
),
rli
(
is_slave_recovery
),
port
(
MYSQL_PORT
),
rli
(
is_slave_recovery
),
abort_slave
(
0
),
connect_retry
(
DEFAULT_CONNECT_RETRY
),
inited
(
0
),
abort_slave
(
0
),
slave_running
(
0
),
slave_run_id
(
0
),
sync_counter
(
0
),
slave_running
(
0
),
slave_run_id
(
0
),
sync_counter
(
0
),
heartbeat_period
(
0
),
received_heartbeats
(
0
),
master_id
(
0
)
heartbeat_period
(
0
),
received_heartbeats
(
0
),
master_id
(
0
)
{
{
...
...
sql/slave.cc
View file @
51af6729
...
@@ -1111,7 +1111,7 @@ int init_dynarray_intvar_from_file(DYNAMIC_ARRAY* arr, IO_CACHE* f)
...
@@ -1111,7 +1111,7 @@ int init_dynarray_intvar_from_file(DYNAMIC_ARRAY* arr, IO_CACHE* f)
memcpy
(
buf_act
,
buf
,
read_size
);
memcpy
(
buf_act
,
buf
,
read_size
);
snd_size
=
my_b_gets
(
f
,
buf_act
+
read_size
,
max_size
-
read_size
);
snd_size
=
my_b_gets
(
f
,
buf_act
+
read_size
,
max_size
-
read_size
);
if
(
snd_size
==
0
||
if
(
snd_size
==
0
||
(
snd_size
+
1
==
max_size
-
read_size
)
&&
buf
[
max_size
-
2
]
!=
'\n'
)
(
(
snd_size
+
1
==
max_size
-
read_size
)
&&
buf
[
max_size
-
2
]
!=
'\n'
)
)
{
{
/*
/*
failure to make the 2nd read or short read again
failure to make the 2nd read or short read again
...
@@ -3943,8 +3943,8 @@ static int queue_event(Master_info* mi,const char* buf, ulong event_len)
...
@@ -3943,8 +3943,8 @@ static int queue_event(Master_info* mi,const char* buf, ulong event_len)
/* everything is filtered out from non-master */
/* everything is filtered out from non-master */
(
s_id
!=
mi
->
master_id
||
(
s_id
!=
mi
->
master_id
||
/* for the master meta information is necessary */
/* for the master meta information is necessary */
buf
[
EVENT_TYPE_OFFSET
]
!=
FORMAT_DESCRIPTION_EVENT
&&
(
buf
[
EVENT_TYPE_OFFSET
]
!=
FORMAT_DESCRIPTION_EVENT
&&
buf
[
EVENT_TYPE_OFFSET
]
!=
ROTATE_EVENT
)))
buf
[
EVENT_TYPE_OFFSET
]
!=
ROTATE_EVENT
)
)))
{
{
/*
/*
Do not write it to the relay log.
Do not write it to the relay log.
...
@@ -3964,9 +3964,9 @@ static int queue_event(Master_info* mi,const char* buf, ulong event_len)
...
@@ -3964,9 +3964,9 @@ static int queue_event(Master_info* mi,const char* buf, ulong event_len)
as well as rli->group_relay_log_pos.
as well as rli->group_relay_log_pos.
*/
*/
if
(
!
(
s_id
==
::
server_id
&&
!
mi
->
rli
.
replicate_same_server_id
)
||
if
(
!
(
s_id
==
::
server_id
&&
!
mi
->
rli
.
replicate_same_server_id
)
||
buf
[
EVENT_TYPE_OFFSET
]
!=
FORMAT_DESCRIPTION_EVENT
&&
(
buf
[
EVENT_TYPE_OFFSET
]
!=
FORMAT_DESCRIPTION_EVENT
&&
buf
[
EVENT_TYPE_OFFSET
]
!=
ROTATE_EVENT
&&
buf
[
EVENT_TYPE_OFFSET
]
!=
ROTATE_EVENT
&&
buf
[
EVENT_TYPE_OFFSET
]
!=
STOP_EVENT
)
buf
[
EVENT_TYPE_OFFSET
]
!=
STOP_EVENT
)
)
{
{
mi
->
master_log_pos
+=
inc_pos
;
mi
->
master_log_pos
+=
inc_pos
;
memcpy
(
rli
->
ign_master_log_name_end
,
mi
->
master_log_name
,
FN_REFLEN
);
memcpy
(
rli
->
ign_master_log_name_end
,
mi
->
master_log_name
,
FN_REFLEN
);
...
...
sql/sql_class.cc
View file @
51af6729
...
@@ -3531,7 +3531,7 @@ int THD::decide_logging_format(TABLE_LIST *tables)
...
@@ -3531,7 +3531,7 @@ int THD::decide_logging_format(TABLE_LIST *tables)
{
{
DBUG_ENTER
(
"THD::decide_logging_format"
);
DBUG_ENTER
(
"THD::decide_logging_format"
);
DBUG_PRINT
(
"info"
,
(
"query: %s"
,
query
()));
DBUG_PRINT
(
"info"
,
(
"query: %s"
,
query
()));
DBUG_PRINT
(
"info"
,
(
"variables.binlog_format: %
ld
"
,
DBUG_PRINT
(
"info"
,
(
"variables.binlog_format: %
u
"
,
variables
.
binlog_format
));
variables
.
binlog_format
));
DBUG_PRINT
(
"info"
,
(
"lex->get_stmt_unsafe_flags(): 0x%x"
,
DBUG_PRINT
(
"info"
,
(
"lex->get_stmt_unsafe_flags(): 0x%x"
,
lex
->
get_stmt_unsafe_flags
()));
lex
->
get_stmt_unsafe_flags
()));
...
@@ -3672,7 +3672,7 @@ int THD::decide_logging_format(TABLE_LIST *tables)
...
@@ -3672,7 +3672,7 @@ int THD::decide_logging_format(TABLE_LIST *tables)
lock history on the slave will be different from the master.
lock history on the slave will be different from the master.
*/
*/
if
(
mixed_engine
||
if
(
mixed_engine
||
trans_has_updated_trans_table
(
this
)
&&
!
all_trans_engines
)
(
trans_has_updated_trans_table
(
this
)
&&
!
all_trans_engines
)
)
lex
->
set_stmt_unsafe
(
LEX
::
BINLOG_STMT_UNSAFE_NONTRANS_AFTER_TRANS
);
lex
->
set_stmt_unsafe
(
LEX
::
BINLOG_STMT_UNSAFE_NONTRANS_AFTER_TRANS
);
DBUG_PRINT
(
"info"
,
(
"flags_all_set: 0x%llx"
,
flags_all_set
));
DBUG_PRINT
(
"info"
,
(
"flags_all_set: 0x%llx"
,
flags_all_set
));
...
@@ -3802,7 +3802,7 @@ int THD::decide_logging_format(TABLE_LIST *tables)
...
@@ -3802,7 +3802,7 @@ int THD::decide_logging_format(TABLE_LIST *tables)
DBUG_PRINT
(
"info"
,
(
"decision: no logging since "
DBUG_PRINT
(
"info"
,
(
"decision: no logging since "
"mysql_bin_log.is_open() = %d "
"mysql_bin_log.is_open() = %d "
"and (options & OPTION_BIN_LOG) = 0x%llx "
"and (options & OPTION_BIN_LOG) = 0x%llx "
"and binlog_format = %
ld
"
"and binlog_format = %
u
"
"and binlog_filter->db_ok(db) = %d"
,
"and binlog_filter->db_ok(db) = %d"
,
mysql_bin_log
.
is_open
(),
mysql_bin_log
.
is_open
(),
(
variables
.
option_bits
&
OPTION_BIN_LOG
),
(
variables
.
option_bits
&
OPTION_BIN_LOG
),
...
...
sql/sql_db.cc
View file @
51af6729
...
@@ -854,7 +854,7 @@ bool mysql_alter_db(THD *thd, const char *db, HA_CREATE_INFO *create_info)
...
@@ -854,7 +854,7 @@ bool mysql_alter_db(THD *thd, const char *db, HA_CREATE_INFO *create_info)
qinfo
.
db_len
=
strlen
(
db
);
qinfo
.
db_len
=
strlen
(
db
);
/* These DDL methods and logging protected with LOCK_mysql_create_db */
/* These DDL methods and logging protected with LOCK_mysql_create_db */
if
(
error
=
mysql_bin_log
.
write
(
&
qinfo
))
if
(
(
error
=
mysql_bin_log
.
write
(
&
qinfo
)
))
goto
exit
;
goto
exit
;
}
}
my_ok
(
thd
,
result
);
my_ok
(
thd
,
result
);
...
...
sql/sql_parse.cc
View file @
51af6729
...
@@ -3887,7 +3887,7 @@ end_with_restore_list:
...
@@ -3887,7 +3887,7 @@ end_with_restore_list:
*/
*/
if
(
!
lex
->
no_write_to_binlog
&&
write_to_binlog
)
if
(
!
lex
->
no_write_to_binlog
&&
write_to_binlog
)
{
{
if
(
res
=
write_bin_log
(
thd
,
FALSE
,
thd
->
query
(),
thd
->
query_length
(
)))
if
(
(
res
=
write_bin_log
(
thd
,
FALSE
,
thd
->
query
(),
thd
->
query_length
()
)))
break
;
break
;
}
}
my_ok
(
thd
);
my_ok
(
thd
);
...
...
sql/sql_repl.cc
View file @
51af6729
...
@@ -828,11 +828,11 @@ impossible position";
...
@@ -828,11 +828,11 @@ impossible position";
{
{
if
(
coord
)
if
(
coord
)
{
{
DBUG_ASSERT
(
heartbeat_ts
&&
heartbeat_period
!=
LL
(
0
)
);
DBUG_ASSERT
(
heartbeat_ts
&&
heartbeat_period
!=
0
);
set_timespec_nsec
(
*
heartbeat_ts
,
heartbeat_period
);
set_timespec_nsec
(
*
heartbeat_ts
,
heartbeat_period
);
}
}
ret
=
mysql_bin_log
.
wait_for_update_bin_log
(
thd
,
heartbeat_ts
);
ret
=
mysql_bin_log
.
wait_for_update_bin_log
(
thd
,
heartbeat_ts
);
DBUG_ASSERT
(
ret
==
0
||
heartbeat_period
!=
LL
(
0
)
&&
coord
!=
NULL
);
DBUG_ASSERT
(
ret
==
0
||
(
heartbeat_period
!=
0
&&
coord
!=
NULL
)
);
if
(
ret
==
ETIMEDOUT
||
ret
==
ETIME
)
if
(
ret
==
ETIMEDOUT
||
ret
==
ETIME
)
{
{
#ifndef DBUG_OFF
#ifndef DBUG_OFF
...
...
sql/sql_table.cc
View file @
51af6729
...
@@ -6533,7 +6533,7 @@ bool mysql_alter_table(THD *thd,char *new_db, char *new_name,
...
@@ -6533,7 +6533,7 @@ bool mysql_alter_table(THD *thd,char *new_db, char *new_name,
thd
->
clear_error
();
thd
->
clear_error
();
Query_log_event
qinfo
(
thd
,
thd
->
query
(),
thd
->
query_length
(),
Query_log_event
qinfo
(
thd
,
thd
->
query
(),
thd
->
query_length
(),
FALSE
,
TRUE
,
FALSE
,
0
);
FALSE
,
TRUE
,
FALSE
,
0
);
if
(
error
=
mysql_bin_log
.
write
(
&
qinfo
))
if
(
(
error
=
mysql_bin_log
.
write
(
&
qinfo
)
))
goto
view_err_unlock
;
goto
view_err_unlock
;
}
}
my_ok
(
thd
);
my_ok
(
thd
);
...
...
sql/sys_vars.cc
View file @
51af6729
...
@@ -324,7 +324,7 @@ static bool binlog_direct_check(sys_var *self, THD *thd, set_var *var)
...
@@ -324,7 +324,7 @@ static bool binlog_direct_check(sys_var *self, THD *thd, set_var *var)
return
true
;
return
true
;
if
(
var
->
type
==
OPT_GLOBAL
||
if
(
var
->
type
==
OPT_GLOBAL
||
(
thd
->
variables
.
binlog_direct_non_trans_update
==
(
thd
->
variables
.
binlog_direct_non_trans_update
==
var
->
save_result
.
ulonglong_value
))
static_cast
<
my_bool
>
(
var
->
save_result
.
ulonglong_value
)
))
return
false
;
return
false
;
return
false
;
return
false
;
...
...
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