From 892ab41d3554bb7e225b921df4d2873547ce8c2c Mon Sep 17 00:00:00 2001 From: Marcin Siodelski Date: Thu, 18 Oct 2018 12:12:25 +0200 Subject: [#93,!63] Throw exception if the server selector is unassigned. --- src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc') diff --git a/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc b/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc index 6c446fd25e..01ced7ad9f 100644 --- a/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc +++ b/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc @@ -85,6 +85,12 @@ uint64_t MySqlConfigBackendImpl::deleteFromTable(const int index, const ServerSelector& server_selector, const std::string& operation) { + + if (server_selector.amUnassigned()) { + isc_throw(NotImplemented, "managing configuration for no particular server" + " (unassigned) is unsupported at the moment"); + } + auto tag = getServerTag(server_selector, operation); MySqlBindingCollection in_bindings = { -- cgit v1.2.3