summaryrefslogtreecommitdiffstats
path: root/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc
diff options
context:
space:
mode:
authorMarcin Siodelski <marcin@isc.org>2018-10-18 12:12:25 +0200
committerMarcin Siodelski <marcin@isc.org>2018-10-18 13:35:08 +0200
commit892ab41d3554bb7e225b921df4d2873547ce8c2c (patch)
tree2cd62aa0b78fc74ef697fe0f686404109015a25a /src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc
parent[#93,!63] Implemented getHost() and getPort() MySQL backend functions. (diff)
downloadkea-892ab41d3554bb7e225b921df4d2873547ce8c2c.tar.xz
kea-892ab41d3554bb7e225b921df4d2873547ce8c2c.zip
[#93,!63] Throw exception if the server selector is unassigned.
Diffstat (limited to 'src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc')
-rw-r--r--src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc6
1 files changed, 6 insertions, 0 deletions
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 = {