Loading sql/slave.cc +26 −26 Original line number Diff line number Diff line Loading @@ -917,10 +917,10 @@ static int exec_event(THD* thd, NET* net, MASTER_INFO* mi, int event_len) { const char* errmsg = "Slave: did not get the expected error\ running query from master - expected: '%s'(%d), got '%s'(%d)"; sql_print_error(errmsg, ER(expected_error), expected_error, sql_print_error(errmsg, ER_SAFE(expected_error), expected_error, actual_error ? thd->net.last_error:"no error", actual_error ); actual_error); thd->query_error = 1; } else if (expected_error == actual_error) Loading @@ -930,9 +930,9 @@ static int exec_event(THD* thd, NET* net, MASTER_INFO* mi, int event_len) last_slave_errno = 0; } } else // master could be inconsistent, abort and tell DBA to // check/fix it else { // master could be inconsistent, abort and tell DBA to check/fix it thd->db = thd->query = 0; thd->convert_set = 0; close_thread_tables(thd); Loading sql/unireg.h +3 −2 Original line number Diff line number Diff line Loading @@ -37,8 +37,9 @@ #define SHAREDIR "share/" #endif #define ER(X) ((X) >= 1000 && (X) < ER_ERROR_MESSAGES + 1000) ? \ errmesg[(X)-1000] : "Invalid error code" #define ER(X) errmesg[(X)-1000] #define ER_SAFE(X) (((X) >= 1000 && (X) < ER_ERROR_MESSAGES + 1000) ? ER(X) : "Invalid error code") #define ERRMAPP 1 /* Errormap f|r my_error */ #define LIBLEN FN_REFLEN-FN_LEN /* Max l{ngd p} dev */ Loading Loading
sql/slave.cc +26 −26 Original line number Diff line number Diff line Loading @@ -917,10 +917,10 @@ static int exec_event(THD* thd, NET* net, MASTER_INFO* mi, int event_len) { const char* errmsg = "Slave: did not get the expected error\ running query from master - expected: '%s'(%d), got '%s'(%d)"; sql_print_error(errmsg, ER(expected_error), expected_error, sql_print_error(errmsg, ER_SAFE(expected_error), expected_error, actual_error ? thd->net.last_error:"no error", actual_error ); actual_error); thd->query_error = 1; } else if (expected_error == actual_error) Loading @@ -930,9 +930,9 @@ static int exec_event(THD* thd, NET* net, MASTER_INFO* mi, int event_len) last_slave_errno = 0; } } else // master could be inconsistent, abort and tell DBA to // check/fix it else { // master could be inconsistent, abort and tell DBA to check/fix it thd->db = thd->query = 0; thd->convert_set = 0; close_thread_tables(thd); Loading
sql/unireg.h +3 −2 Original line number Diff line number Diff line Loading @@ -37,8 +37,9 @@ #define SHAREDIR "share/" #endif #define ER(X) ((X) >= 1000 && (X) < ER_ERROR_MESSAGES + 1000) ? \ errmesg[(X)-1000] : "Invalid error code" #define ER(X) errmesg[(X)-1000] #define ER_SAFE(X) (((X) >= 1000 && (X) < ER_ERROR_MESSAGES + 1000) ? ER(X) : "Invalid error code") #define ERRMAPP 1 /* Errormap f|r my_error */ #define LIBLEN FN_REFLEN-FN_LEN /* Max l{ngd p} dev */ Loading