Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sebastian Schrader
Kea
Commits
d8cd8b68
Commit
d8cd8b68
authored
Oct 01, 2017
by
Francis Dupont
Browse files
[5267] Fixed LoggingInfo::toElement
parent
cdfbc195
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/lib/dhcpsrv/logging_info.cc
View file @
d8cd8b68
...
...
@@ -161,14 +161,16 @@ LoggingInfo::toElement() const {
ElementPtr
result
=
Element
::
createMap
();
// Set name
result
->
set
(
"name"
,
Element
::
create
(
name_
));
// Set output_options
ElementPtr
options
=
Element
::
createList
();
for
(
std
::
vector
<
LoggingDestination
>::
const_iterator
dest
=
destinations_
.
cbegin
();
dest
!=
destinations_
.
cend
();
++
dest
)
{
options
->
add
(
dest
->
toElement
());
// Set output_options if not empty
if
(
!
destinations_
.
empty
())
{
ElementPtr
options
=
Element
::
createList
();
for
(
std
::
vector
<
LoggingDestination
>::
const_iterator
dest
=
destinations_
.
cbegin
();
dest
!=
destinations_
.
cend
();
++
dest
)
{
options
->
add
(
dest
->
toElement
());
}
result
->
set
(
"output_options"
,
options
);
}
result
->
set
(
"output_options"
,
options
);
// Set severity
std
::
string
severity
;
switch
(
severity_
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment