bugfix ajax kill of running query (id check untested)

This commit is contained in:
Xenomporio 2022-05-23 12:49:54 +02:00
parent fd0b6378eb
commit 87daa014d3

View File

@ -1495,7 +1495,16 @@ class DB{
if($pid <= 0) {
return false;
}
return mysqli_query($this->connection, 'KILL QUERY '.$pid);
// Get list of processes
$list_of_processes = mysqli_query($this->connection, "select id from information_schema.processlist where id=$pid");
if (get_class($list_of_processes) == 'mysqli') {
if (mysqli_num_rows($list_of_processes) > 0) {
$result = mysqli_query($this->connection, 'KILL QUERY '.$pid);
return($result);
}
}
return(false);
}
/**