summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2019-03-16 19:24:49 +0100
committerSergei Golubchik <serg@mariadb.org>2019-03-27 22:51:37 +0100
commitf97d879bf890fe1d93c459f46410e2be8d26d3b6 (patch)
tree948a0951ebc0b32f9ed4b61aebf7143355a7a815 /sql
parent1a4746e1285bbe03d616310cd49c3548825d5a1a (diff)
downloadmariadb-git-f97d879bf890fe1d93c459f46410e2be8d26d3b6.tar.gz
cmake: re-enable -Werror in the maintainer mode
now we can afford it. Fix -Werror errors. Note: * old gcc is bad at detecting uninit variables, disable it. * time_t is int or long, cast it for printf's
Diffstat (limited to 'sql')
-rw-r--r--sql/log.cc6
-rw-r--r--sql/sql_admin.cc4
-rw-r--r--sql/wsrep_sst.cc9
3 files changed, 9 insertions, 10 deletions
diff --git a/sql/log.cc b/sql/log.cc
index a1e7e5b218f..bab250223f3 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -9593,9 +9593,9 @@ TC_LOG_BINLOG::log_and_order(THD *thd, my_xid xid, bool all,
*/
if (!xid || !need_unlog)
DBUG_RETURN(BINLOG_COOKIE_DUMMY(cache_mngr->delayed_error));
- else
- DBUG_RETURN(BINLOG_COOKIE_MAKE(cache_mngr->binlog_id,
- cache_mngr->delayed_error));
+
+ DBUG_RETURN(BINLOG_COOKIE_MAKE(cache_mngr->binlog_id,
+ cache_mngr->delayed_error));
}
/*
diff --git a/sql/sql_admin.cc b/sql/sql_admin.cc
index cbc9780d507..0ec6719037c 100644
--- a/sql/sql_admin.cc
+++ b/sql/sql_admin.cc
@@ -528,7 +528,8 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables,
if (!table->table->part_info)
{
my_error(ER_PARTITION_MGMT_ON_NONPARTITIONED, MYF(0));
- goto err2;
+ thd->resume_subsequent_commits(suspended_wfc);
+ DBUG_RETURN(TRUE);
}
if (set_part_state(alter_info, table->table->part_info, PART_ADMIN))
{
@@ -1159,7 +1160,6 @@ err:
}
close_thread_tables(thd); // Shouldn't be needed
thd->mdl_context.release_transactional_locks();
-err2:
thd->resume_subsequent_commits(suspended_wfc);
DBUG_RETURN(TRUE);
}
diff --git a/sql/wsrep_sst.cc b/sql/wsrep_sst.cc
index e2c55583594..addbfeb99f6 100644
--- a/sql/wsrep_sst.cc
+++ b/sql/wsrep_sst.cc
@@ -231,7 +231,7 @@ bool wsrep_sst_wait ()
total_wtime += difftime(end_time, start_time);
WSREP_DEBUG("Waiting for SST to complete. current seqno: %" PRId64 " waited %f secs.", local_seqno, total_wtime);
service_manager_extend_timeout(WSREP_EXTEND_TIMEOUT_INTERVAL,
- "WSREP state transfer ongoing, current seqno: %ld waited %f secs", local_seqno, total_wtime);
+ "WSREP state transfer ongoing, current seqno: %" PRId64 " waited %f secs", local_seqno, total_wtime);
}
}
@@ -294,9 +294,8 @@ void wsrep_sst_received (wsrep_t* const wsrep,
}
else if (local_seqno > seqno)
{
- WSREP_WARN("SST postion is in the past: %lld, current: %lld. "
- "Can't continue.",
- (long long)seqno, (long long)local_seqno);
+ WSREP_WARN("SST postion is in the past: %" PRId64 ", current: %" PRId64
+ ". Can't continue.", seqno, local_seqno);
unireg_abort(1);
}
@@ -1416,7 +1415,7 @@ void wsrep_SE_init_wait()
total_wtime += difftime(end_time, start_time);
WSREP_DEBUG("Waiting for SST to complete. current seqno: %" PRId64 " waited %f secs.", local_seqno, total_wtime);
service_manager_extend_timeout(WSREP_EXTEND_TIMEOUT_INTERVAL,
- "WSREP state transfer ongoing, current seqno: %ld waited %f secs", local_seqno, total_wtime);
+ "WSREP state transfer ongoing, current seqno: %" PRId64 " waited %f secs", local_seqno, total_wtime);
}
}