Skip to content

Commit e0dc22b

Browse files
committed
MDEV-27753 Incorrect ENGINE type of table after crash for CONNECT table
fix two null pointer dereferences
1 parent f4fb6cb commit e0dc22b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

sql/ddl_log.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2484,11 +2484,11 @@ bool ddl_log_write_entry(DDL_LOG_ENTRY *ddl_log_entry,
24842484

24852485
if (unlikely(write_ddl_log_file_entry((*active_entry)->entry_pos)))
24862486
{
2487+
sql_print_error("DDL_LOG: Failed to write entry %u",
2488+
(*active_entry)->entry_pos);
24872489
ddl_log_release_memory_entry(*active_entry);
24882490
*active_entry= 0;
24892491
error= TRUE;
2490-
sql_print_error("DDL_LOG: Failed to write entry %u",
2491-
(*active_entry)->entry_pos);
24922492
}
24932493
DBUG_RETURN(error);
24942494
}
@@ -2545,13 +2545,13 @@ bool ddl_log_write_execute_entry(uint first_entry,
25452545
}
25462546
if (write_ddl_log_file_entry((*active_entry)->entry_pos))
25472547
{
2548+
sql_print_error("DDL_LOG: Error writing execute entry %u",
2549+
(*active_entry)->entry_pos);
25482550
if (got_free_entry)
25492551
{
25502552
ddl_log_release_memory_entry(*active_entry);
25512553
*active_entry= 0;
25522554
}
2553-
sql_print_error("DDL_LOG: Error writing execute entry %u",
2554-
(*active_entry)->entry_pos);
25552555
DBUG_RETURN(TRUE);
25562556
}
25572557
(void) ddl_log_sync_no_lock();

0 commit comments

Comments
 (0)