From f089f8d95e569291bdf4329124c34674f02e40fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Wed, 6 Apr 2022 08:59:41 +0300 Subject: [PATCH] MDEV-23328 fixup: sign mismatch in format strings kill_one_thread(): Fix integer sign mismatch in some format strings. Some of this was introduced in commit 5c230b21bfa582ac304db526c3638c514cf98b13 --- sql/sql_parse.cc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index 35310d2655a..e3efa2d051c 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -1,5 +1,5 @@ /* Copyright (c) 2000, 2017, Oracle and/or its affiliates. - Copyright (c) 2008, 2021, MariaDB + Copyright (c) 2008, 2022, MariaDB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -9176,7 +9176,7 @@ kill_one_thread(THD *thd, longlong id, killed_state kill_signal, killed_type typ THD *tmp; uint error= (type == KILL_TYPE_QUERY ? ER_NO_SUCH_QUERY : ER_NO_SUCH_THREAD); DBUG_ENTER("kill_one_thread"); - DBUG_PRINT("enter", ("id: %lld signal: %u", id, (uint) kill_signal)); + DBUG_PRINT("enter", ("id: %lld signal: %d", id, kill_signal)); tmp= find_thread_by_id(id, type == KILL_TYPE_QUERY); if (!tmp) DBUG_RETURN(error); @@ -9220,14 +9220,15 @@ kill_one_thread(THD *thd, longlong id, killed_state kill_signal, killed_type typ if (tmp->wsrep_aborter && tmp->wsrep_aborter != thd->thread_id) { /* victim is in hit list already, bail out */ - WSREP_DEBUG("victim %llu has wsrep aborter: %lu, skipping awake()", + WSREP_DEBUG("victim %lld has wsrep aborter: %lu, skipping awake()", id, tmp->wsrep_aborter); error= 0; } else #endif /* WITH_WSREP */ { - WSREP_DEBUG("kill_one_thread victim: %llu wsrep_aborter %lu by signal %d", + WSREP_DEBUG("kill_one_thread victim: %lld wsrep_aborter %lu" + " by signal %d", id, tmp->wsrep_aborter, kill_signal); tmp->awake_no_mutex(kill_signal); error= 0; @@ -9240,7 +9241,7 @@ kill_one_thread(THD *thd, longlong id, killed_state kill_signal, killed_type typ mysql_mutex_unlock(&tmp->LOCK_thd_data); } mysql_mutex_unlock(&tmp->LOCK_thd_kill); - DBUG_PRINT("exit", ("%d", error)); + DBUG_PRINT("exit", ("%u", error)); DBUG_RETURN(error); }