| 5162 | - add if (!thd) thd= current_thd here |
| 5163 | */ |
| 5164 | extern "C" enum thd_kill_levels thd_kill_level(const MYSQL_THD thd) |
| 5165 | { |
| 5166 | DBUG_ASSERT(thd); |
| 5167 | |
| 5168 | if (likely(thd->killed == NOT_KILLED)) |
| 5169 | { |
| 5170 | Apc_target *apc_target= (Apc_target*) &thd->apc_target; |
| 5171 | if (unlikely(apc_target->have_apc_requests())) |
| 5172 | { |
| 5173 | if (thd == current_thd) |
| 5174 | apc_target->process_apc_requests(false); |
| 5175 | } |
| 5176 | return THD_IS_NOT_KILLED; |
| 5177 | } |
| 5178 | |
| 5179 | return thd->killed & KILL_HARD_BIT ? THD_ABORT_ASAP : THD_ABORT_SOFTLY; |
| 5180 | } |
| 5181 | |
| 5182 | |
| 5183 | /** |
no test coverage detected