Commit bd42a66f authored by Francis Dupont's avatar Francis Dupont
Browse files

[master] Finished merge of trac3920 (data_ defined twice)

parents c97ae477 65c611f2
979. [bug] fdupont
Fixed two cases of public variables in a base class being
hidden by variables in a derived class.
(Trac #3920, git xxx)
978. [func] tmark
DHCPv4, DHCPv6, and DHCP_DDNS now all create PID files upon
startup. The PID file pathname is formed from:
......@@ -44,7 +44,7 @@ DControllerBase::DControllerBase(const char* app_name, const char* bin_name)
: app_name_(app_name), bin_name_(bin_name),
verbose_(false), spec_file_name_(""),
io_service_(new isc::asiolink::IOService()),
signal_set_(), io_signal_queue_() {
io_signal_queue_() {
......@@ -23,7 +23,6 @@
#include <dhcpsrv/daemon.h>
#include <exceptions/exceptions.h>
#include <log/logger_support.h>
#include <util/signal_set.h>
#include <boost/shared_ptr.hpp>
#include <boost/noncopyable.hpp>
......@@ -506,9 +505,6 @@ private:
/// @brief Shared pointer to an IOService object, used for ASIO operations.
asiolink::IOServicePtr io_service_;
/// @brief Set of registered signals to handle.
util::SignalSetPtr signal_set_;
/// @brief Queue for propagating caught signals to the IOService.
IOSignalQueuePtr io_signal_queue_;
......@@ -48,8 +48,12 @@ Pkt::Pkt(const uint8_t* buf, uint32_t len, const isc::asiolink::IOAddress& local
if (len) {
if (len != 0) {
if (buf == NULL) {
isc_throw(InvalidParameter, "data buffer passed to Pkt is NULL");
memcpy(&data_[0], buf, len);
......@@ -74,14 +74,7 @@ Pkt4::Pkt4(const uint8_t* data, size_t len)
isc_throw(OutOfRange, "Truncated DHCPv4 packet (len=" << len
<< ") received, at least " << DHCPV4_PKT_HDR_LEN
<< " is expected.");
} else if (data == NULL) {
isc_throw(InvalidParameter, "data buffer passed to Pkt4 is NULL");
memcpy(&data_[0], data, len);
memset(sname_, 0, MAX_SNAME_LEN);
memset(file_, 0, MAX_FILE_LEN);
......@@ -366,24 +366,6 @@ public:
/// (true) or non-relayed (false).
bool isRelayed() const;
/// @brief That's the data of input buffer used in RX packet.
/// @note Note that InputBuffer does not store the data itself, but just
/// expects that data will be valid for the whole life of InputBuffer.
/// Therefore we need to keep the data around.
/// @warning This public member is accessed by derived
/// classes directly. One of such derived classes is
/// @ref perfdhcp::PerfPkt4. The impact on derived clasess'
/// behavior must be taken into consideration before making
/// changes to this member such as access scope restriction or
/// data format change etc. This field is also public, because
/// it may be modified by callouts (which are written in C++ now,
/// but we expect to also have them in Python, so any accesibility
/// methods would overly complicate things here and degrade
/// performance).
std::vector<uint8_t> data_;
/// @brief Generic method that validates and sets HW address.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment