MCPcopy Create free account
hub / github.com/MariaDB/server / handle_condition

Method handle_condition

sql/ddl_log.cc:927–949  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

925 {}
926
927 bool handle_condition(THD *,
928 uint sql_errno,
929 const char*,
930 Sql_condition::enum_warning_level *level,
931 const char*,
932 Sql_condition **cond_hdl) override
933 {
934 *cond_hdl= NULL;
935 if (non_existing_table_error(sql_errno) ||
936 (!only_ignore_non_existing_errors &&
937 (sql_errno == EE_LINK ||
938 sql_errno == EE_DELETE || sql_errno == ER_TRG_NO_DEFINER)))
939 {
940 handled_errors++;
941 return TRUE;
942 }
943 if (!first_error)
944 first_error= sql_errno;
945
946 if (*level == Sql_condition::WARN_LEVEL_ERROR)
947 unhandled_errors++;
948 return FALSE;
949 }
950 bool safely_trapped_errors()
951 {
952 return (handled_errors > 0 && unhandled_errors == 0);

Callers

nothing calls this directly

Calls 1

non_existing_table_errorFunction · 0.85

Tested by

no test coverage detected