| 6153 | */ |
| 6154 | |
| 6155 | static my_bool delete_table_force(THD *thd, plugin_ref plugin, void *arg) |
| 6156 | { |
| 6157 | handlerton *hton = plugin_hton(plugin); |
| 6158 | st_force_drop_table_params *param = (st_force_drop_table_params *)arg; |
| 6159 | |
| 6160 | if (param->discovering == (hton->discover_table != NULL) && |
| 6161 | !(thd->slave_thread && (hton->flags & HTON_IGNORE_UPDATES))) |
| 6162 | { |
| 6163 | int error; |
| 6164 | error= ha_delete_table(thd, hton, param->path, param->db, param->alias, 0); |
| 6165 | if (error > 0 && !non_existing_table_error(error)) |
| 6166 | param->error= error; |
| 6167 | if (error == 0) |
| 6168 | { |
| 6169 | if (hton && hton->flags & HTON_TABLE_MAY_NOT_EXIST_ON_SLAVE) |
| 6170 | thd->replication_flags |= OPTION_IF_EXISTS; |
| 6171 | param->error= 0; |
| 6172 | return TRUE; // Table was deleted |
| 6173 | } |
| 6174 | } |
| 6175 | return FALSE; |
| 6176 | } |
| 6177 | |
| 6178 | /** |
| 6179 | @brief |
nothing calls this directly
no test coverage detected