Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sebastian Schrader
Kea
Commits
a9d957c1
Commit
a9d957c1
authored
Jun 14, 2013
by
Michal 'vorner' Vaner
Browse files
[2726] Initialize variables
parent
87808673
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/lib/dns/rrttl.cc
View file @
a9d957c1
...
@@ -74,10 +74,11 @@ parseTTLString(const string& ttlstr, uint32_t& ttlval, string* error_txt) {
...
@@ -74,10 +74,11 @@ parseTTLString(const string& ttlstr, uint32_t& ttlval, string* error_txt) {
const
string
::
const_iterator
end
=
ttlstr
.
end
();
const
string
::
const_iterator
end
=
ttlstr
.
end
();
string
::
const_iterator
pos
=
ttlstr
.
begin
();
string
::
const_iterator
pos
=
ttlstr
.
begin
();
// When we detect we have some units
bool
units_mode
=
false
;
try
{
try
{
// When we detect we have some units
bool
units_mode
=
false
;
while
(
pos
!=
end
)
{
while
(
pos
!=
end
)
{
// Find the first unit, if there's any.
// Find the first unit, if there's any.
const
string
::
const_iterator
unit
=
find_if
(
pos
,
end
,
myIsalpha
);
const
string
::
const_iterator
unit
=
find_if
(
pos
,
end
,
myIsalpha
);
...
...
src/lib/log/message_exception.h
View file @
a9d957c1
...
@@ -62,7 +62,7 @@ public:
...
@@ -62,7 +62,7 @@ public:
/// \param lineno Line number on which error occurred (if > 0).
/// \param lineno Line number on which error occurred (if > 0).
MessageException
(
const
char
*
file
,
size_t
line
,
const
char
*
what
,
MessageException
(
const
char
*
file
,
size_t
line
,
const
char
*
what
,
MessageID
id
,
const
std
::
string
&
arg1
,
int
lineno
)
MessageID
id
,
const
std
::
string
&
arg1
,
int
lineno
)
:
isc
::
Exception
(
file
,
line
,
what
),
id_
(
id
)
:
isc
::
Exception
(
file
,
line
,
what
),
id_
(
id
)
,
lineno_
(
lineno
)
{
{
if
(
lineno
>
0
)
{
if
(
lineno
>
0
)
{
args_
.
push_back
(
boost
::
lexical_cast
<
std
::
string
>
(
lineno
));
args_
.
push_back
(
boost
::
lexical_cast
<
std
::
string
>
(
lineno
));
...
@@ -82,7 +82,7 @@ public:
...
@@ -82,7 +82,7 @@ public:
MessageException
(
const
char
*
file
,
size_t
line
,
const
char
*
what
,
MessageException
(
const
char
*
file
,
size_t
line
,
const
char
*
what
,
MessageID
id
,
const
std
::
string
&
arg1
,
MessageID
id
,
const
std
::
string
&
arg1
,
const
std
::
string
&
arg2
,
int
lineno
)
const
std
::
string
&
arg2
,
int
lineno
)
:
isc
::
Exception
(
file
,
line
,
what
),
id_
(
id
)
:
isc
::
Exception
(
file
,
line
,
what
),
id_
(
id
)
,
lineno_
(
lineno
)
{
{
if
(
lineno
>
0
)
{
if
(
lineno
>
0
)
{
args_
.
push_back
(
boost
::
lexical_cast
<
std
::
string
>
(
lineno
));
args_
.
push_back
(
boost
::
lexical_cast
<
std
::
string
>
(
lineno
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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