From: Razvan Becheriu Date: Wed, 18 May 2022 15:42:26 +0000 (+0300) Subject: [#2227] reverted changes in CB X-Git-Tag: Kea-2.1.6~48 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d35964cc66f3d759abbfd77f0d32302c81c5cd73;p=thirdparty%2Fkea.git [#2227] reverted changes in CB --- diff --git a/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc b/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc index 8ac2492b41..f4a05637f3 100644 --- a/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc +++ b/src/hooks/dhcp/mysql_cb/mysql_cb_impl.cc @@ -967,9 +967,7 @@ MySqlConfigBackendImpl::createOptionValueBinding(const OptionDescriptorPtr& opti OptionPtr opt = option->option_; if (option->formatted_value_.empty() && (opt->len() > opt->getHeaderLen())) { OutputBuffer buf(opt->len()); - // The RFC3396 adds support for long options split over multiple options - // using the same code. - opt->pack(buf, false); + opt->pack(buf); const char* buf_ptr = static_cast(buf.getData()); std::vector blob(buf_ptr + opt->getHeaderLen(), buf_ptr + buf.getLength()); diff --git a/src/hooks/dhcp/pgsql_cb/pgsql_cb_impl.cc b/src/hooks/dhcp/pgsql_cb/pgsql_cb_impl.cc index ea193cc627..4399cb08a2 100644 --- a/src/hooks/dhcp/pgsql_cb/pgsql_cb_impl.cc +++ b/src/hooks/dhcp/pgsql_cb/pgsql_cb_impl.cc @@ -1124,9 +1124,7 @@ PgSqlConfigBackendImpl::addOptionValueBinding(PsqlBindArray& bindings, OptionPtr opt = option->option_; if (option->formatted_value_.empty() && (opt->len() > opt->getHeaderLen())) { OutputBuffer buf(opt->len()); - // The RFC3396 adds support for long options split over multiple options - // using the same code. - opt->pack(buf, false); + opt->pack(buf); const char* buf_ptr = static_cast(buf.getData()); std::vector blob(buf_ptr + opt->getHeaderLen(), buf_ptr + buf.getLength()); diff --git a/src/lib/dhcp/option.h b/src/lib/dhcp/option.h index ce069d2fff..dfb26f378a 100644 --- a/src/lib/dhcp/option.h +++ b/src/lib/dhcp/option.h @@ -242,7 +242,7 @@ public: /// /// @param buf pointer to a buffer /// @param check flag which indicates if checking the option length is - /// required (used in V4 only) + /// required (used only in V4) /// /// @throw BadValue Universe of the option is neither V4 nor V6. virtual void pack(isc::util::OutputBuffer& buf, bool check = true) const;