Commit 78af50a2 authored by Francis Dupont's avatar Francis Dupont
Browse files

[3919] Assign classcode_ to avoid cppcheck warning

parent 997f1395
// Copyright (C) 2010 Internet Systems Consortium, Inc. ("ISC")
// Copyright (C) 2010, 2015 Internet Systems Consortium, Inc. ("ISC")
//
// Permission to use, copy, modify, and/or distribute this software for any
// purpose with or without fee is hereby granted, provided that the above
......@@ -31,10 +31,12 @@ namespace isc {
namespace dns {
RRClass::RRClass(const std::string& class_str) {
if (!RRParamRegistry::getRegistry().textToClassCode(class_str, classcode_)) {
uint16_t classcode;
if (!RRParamRegistry::getRegistry().textToClassCode(class_str, classcode)) {
isc_throw(InvalidRRClass,
"Unrecognized RR class string: " + class_str);
}
classcode_ = classcode;
}
RRClass::RRClass(InputBuffer& buffer) {
......
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