lock0lock.c:

  Fix bug: if SHOW INNODB STATUS or innodb_monitor printed several hundred transactions, the output was truncated and we forgot to release the kernel mutex
parent cbd9978b
......@@ -3599,6 +3599,8 @@ lock_print_info(
mtr_t mtr;
if (buf_end - buf < 600) {
sprintf(buf, "... output truncated!\n");
return;
}
......@@ -3623,6 +3625,9 @@ lock_print_info(
if ((ulint)(buf_end - buf)
< 100 + strlen(lock_latest_err_buf)) {
lock_mutex_exit_kernel();
sprintf(buf, "... output truncated!\n");
return;
}
......@@ -3630,6 +3635,9 @@ lock_print_info(
}
if (buf_end - buf < 600) {
lock_mutex_exit_kernel();
sprintf(buf, "... output truncated!\n");
return;
}
......@@ -3641,6 +3649,9 @@ lock_print_info(
while (trx) {
if (buf_end - buf < 900) {
lock_mutex_exit_kernel();
sprintf(buf, "... output truncated!\n");
return;
}
......@@ -3678,6 +3689,9 @@ lock_print_info(
}
if (buf_end - buf < 900) {
lock_mutex_exit_kernel();
sprintf(buf, "... output truncated!\n");
return;
}
......@@ -3688,6 +3702,9 @@ lock_print_info(
buf += strlen(buf);
if (buf_end - buf < 500) {
lock_mutex_exit_kernel();
sprintf(buf, "... output truncated!\n");
return;
}
......@@ -3742,6 +3759,9 @@ lock_print_info(
}
if (buf_end - buf < 500) {
lock_mutex_exit_kernel();
sprintf(buf, "... output truncated!\n");
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment