From ca536526c3c38196cb7ef2d481fe8835bc00ea71 Mon Sep 17 00:00:00 2001 From: Marcin Siodelski Date: Sat, 6 Jul 2019 20:11:17 +0200 Subject: [PATCH] [#715,!411] Removed dead code from the mysql_cb_impl.cc As a result of the review. --- src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc b/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc index 00c18aef04..17baf3fbd0 100644 --- a/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc +++ b/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc @@ -540,21 +540,6 @@ MySqlConfigBackendImpl::createUpdateOptionDef(const db::ServerSelector& server_s MySqlTransaction transaction(conn_); - // Need to check if this definition already exists. We can't follow - // the same pattern as for shared networks and subnets, to try to insert - // the definition first and fall back to update if the DuplicateEntry - // exception is thrown, because the option code/space is not unique - // within the dhcpX_option_def table. Inserting another option definition - // with existing option code/name would not violate the key and the - // option definition instance would be inserted successfully. Therefore, - // we first fetch the option definition for the given server, code and - // space name. If it exists, we simply update it. - OptionDefinitionPtr existing_definition = - getOptionDef(get_option_def_code_space, - server_selector, - option_def->getCode(), - option_def->getOptionSpaceName()); - // Create scoped audit revision. As long as this instance exists // no new audit revisions are created in any subsequent calls. ScopedAuditRevision audit_revision(this, -- 2.47.2