From: Francis Dupont Date: Sat, 22 Sep 2018 14:47:31 +0000 (+0200) Subject: [65-libyang-control-socket] New fixes X-Git-Tag: 165-netbsd-8-fixes_base^2~3^2^2~1^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4402c0936ebf1d698f18bdbab13656e936992bd3;p=thirdparty%2Fkea.git [65-libyang-control-socket] New fixes --- diff --git a/src/lib/yang/translator_control_socket.cc b/src/lib/yang/translator_control_socket.cc index ad5d0866c7..84f4bfb7b7 100644 --- a/src/lib/yang/translator_control_socket.cc +++ b/src/lib/yang/translator_control_socket.cc @@ -55,8 +55,7 @@ TranslatorControlSocket::getControlSocketKea(const string& xpath) { } return (result); } - isc_throw(Unexpected, "getControlSocketKea rquires name and type: " - << xpath); + return (ElementPtr()); } void diff --git a/src/lib/yang/translator_control_socket.h b/src/lib/yang/translator_control_socket.h index 2ae6bb266f..efd79760c4 100644 --- a/src/lib/yang/translator_control_socket.h +++ b/src/lib/yang/translator_control_socket.h @@ -53,7 +53,7 @@ public: /// @brief Get and translate a control socket from YANG to JSON. /// /// @param xpath The xpath of the control socket. - /// @return JSON representation of the control socket. + /// @return JSON representation of the control socket or null. /// @throw SysrepoError when sysrepo raises an error. isc::data::ConstElementPtr getControlSocket(const std::string& xpath);