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
ISC Open Source Projects
Kea
Commits
346b2a28
Commit
346b2a28
authored
Jun 27, 2015
by
Francis Dupont
Browse files
[master] Finished merge of trac3839 (removed unused exception variables)
parents
8684aede
f50c3a7f
Changes
14
Hide whitespace changes
Inline
Side-by-side
src/bin/perfdhcp/stats_mgr.h
View file @
346b2a28
// Copyright (C) 2012-2013 Internet Systems Consortium, Inc. ("ISC")
// Copyright (C) 2012-2013
, 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
...
...
@@ -665,7 +665,7 @@ public:
<<
"std deviation: "
<<
getStdDevDelay
()
*
1e3
<<
" ms"
<<
endl
<<
"collected packets: "
<<
getCollectedNum
()
<<
endl
;
}
catch
(
const
Exception
&
e
)
{
}
catch
(
const
Exception
&
)
{
cout
<<
"Delay summary unavailable! No packets received."
<<
endl
;
}
}
...
...
src/lib/dhcp/libdhcp++.cc
View file @
346b2a28
...
...
@@ -778,7 +778,7 @@ void initOptionSpace(OptionDefContainer& defs,
try
{
definition
->
validate
();
}
catch
(
const
isc
::
Exception
&
ex
)
{
}
catch
(
const
isc
::
Exception
&
)
{
// This is unlikely event that validation fails and may
// be only caused by programming error. To guarantee the
// data consistency we clear all option definitions that
...
...
src/lib/dhcp/option4_client_fqdn.cc
View file @
346b2a28
...
...
@@ -218,7 +218,7 @@ setDomainName(const std::string& domain_name,
try
{
domain_name_
.
reset
(
new
isc
::
dns
::
Name
(
name
));
}
catch
(
const
Exception
&
ex
)
{
}
catch
(
const
Exception
&
)
{
isc_throw
(
InvalidOption4FqdnDomainName
,
"invalid domain-name value '"
<<
domain_name
<<
"' when setting new domain-name for"
...
...
src/lib/dhcp/option6_client_fqdn.cc
View file @
346b2a28
...
...
@@ -189,7 +189,7 @@ setDomainName(const std::string& domain_name,
try
{
domain_name_
.
reset
(
new
isc
::
dns
::
Name
(
name
,
true
));
}
catch
(
const
Exception
&
ex
)
{
}
catch
(
const
Exception
&
)
{
isc_throw
(
InvalidOption6FqdnDomainName
,
"invalid domain-name value '"
<<
domain_name
<<
"' when setting new domain-name for"
<<
" DHCPv6 Client FQDN Option"
);
...
...
@@ -249,7 +249,7 @@ Option6ClientFqdnImpl::parseWireData(OptionBufferConstIter first,
isc
::
util
::
InputBuffer
name_buf
(
&
buf
[
0
],
buf
.
size
());
try
{
domain_name_
.
reset
(
new
isc
::
dns
::
Name
(
name_buf
,
true
));
}
catch
(
const
Exception
&
ex
)
{
}
catch
(
const
Exception
&
)
{
isc_throw
(
InvalidOption6FqdnDomainName
,
"failed to parse "
"partial domain-name from wire format"
);
}
...
...
@@ -264,7 +264,7 @@ Option6ClientFqdnImpl::parseWireData(OptionBufferConstIter first,
std
::
distance
(
first
,
last
));
try
{
domain_name_
.
reset
(
new
isc
::
dns
::
Name
(
name_buf
,
true
));
}
catch
(
const
Exception
&
ex
)
{
}
catch
(
const
Exception
&
)
{
isc_throw
(
InvalidOption6FqdnDomainName
,
"failed to parse "
"fully qualified domain-name from wire format"
);
}
...
...
src/lib/dhcp_ddns/ncr_msg.cc
View file @
346b2a28
...
...
@@ -507,7 +507,7 @@ NameChangeRequest::setIpAddress(const std::string& value) {
// Validate IP Address.
try
{
ip_io_address_
=
isc
::
asiolink
::
IOAddress
(
value
);
}
catch
(
const
isc
::
asiolink
::
IOError
&
ex
)
{
}
catch
(
const
isc
::
asiolink
::
IOError
&
)
{
isc_throw
(
NcrMessageError
,
"Invalid ip address string for ip_address: "
<<
value
);
}
...
...
src/lib/dhcpsrv/csv_lease_file4.cc
View file @
346b2a28
...
...
@@ -62,7 +62,7 @@ CSVLeaseFile4::append(const Lease4& lease) {
try
{
CSVFile
::
append
(
row
);
}
catch
(
const
std
::
exception
&
ex
)
{
}
catch
(
const
std
::
exception
&
)
{
// Catch any errors so we can bump the error counter than rethrow it
++
write_errs_
;
throw
;
...
...
src/lib/dhcpsrv/csv_lease_file6.cc
View file @
346b2a28
...
...
@@ -61,7 +61,7 @@ CSVLeaseFile6::append(const Lease6& lease) {
}
try
{
CSVFile
::
append
(
row
);
}
catch
(
const
std
::
exception
&
ex
)
{
}
catch
(
const
std
::
exception
&
)
{
// Catch any errors so we can bump the error counter than rethrow it
++
write_errs_
;
throw
;
...
...
src/lib/dhcpsrv/lease_file_loader.h
View file @
346b2a28
...
...
@@ -199,10 +199,10 @@ public:
++
lease
)
{
try
{
lease_file
.
append
(
**
lease
);
}
catch
(
const
isc
::
Exception
&
ex
)
{
// Close the file
lease_file
.
close
();
throw
;
}
catch
(
const
isc
::
Exception
&
)
{
// Close the file
lease_file
.
close
();
throw
;
}
}
...
...
src/lib/dhcpsrv/logging.cc
View file @
346b2a28
...
...
@@ -76,7 +76,7 @@ void LogConfigParser::parseConfigEntry(isc::data::ConstElementPtr entry) {
}
try
{
info
.
severity_
=
isc
::
log
::
getSeverity
(
severity_ptr
->
stringValue
().
c_str
());
}
catch
(
const
std
::
exception
&
ex
)
{
}
catch
(
const
std
::
exception
&
)
{
isc_throw
(
BadValue
,
"Unsupported severity value '"
<<
severity_ptr
->
stringValue
()
<<
"' ("
<<
severity_ptr
->
getPosition
()
<<
")"
);
...
...
src/lib/dhcpsrv/memfile_lease_mgr.cc
View file @
346b2a28
...
...
@@ -201,7 +201,7 @@ LFCSetup::execute() {
.
arg
(
process_
->
getCommandLine
());
pid_
=
process_
->
spawn
();
}
catch
(
const
ProcessSpawnError
&
ex
)
{
}
catch
(
const
ProcessSpawnError
&
)
{
LOG_ERROR
(
dhcpsrv_logger
,
DHCPSRV_MEMFILE_LFC_SPAWN_FAIL
);
}
}
...
...
@@ -690,7 +690,7 @@ Memfile_LeaseMgr::initLeaseFilePath(Universe u) {
std
::
string
persist_val
;
try
{
persist_val
=
getParameter
(
"persist"
);
}
catch
(
const
Exception
&
ex
)
{
}
catch
(
const
Exception
&
)
{
// If parameter persist hasn't been specified, we use a default value
// 'yes'.
persist_val
=
"true"
;
...
...
@@ -708,7 +708,7 @@ Memfile_LeaseMgr::initLeaseFilePath(Universe u) {
std
::
string
lease_file
;
try
{
lease_file
=
getParameter
(
"name"
);
}
catch
(
const
Exception
&
ex
)
{
}
catch
(
const
Exception
&
)
{
lease_file
=
getDefaultLeaseFilePath
(
u
);
}
return
(
lease_file
);
...
...
@@ -794,14 +794,14 @@ Memfile_LeaseMgr::lfcSetup() {
std
::
string
lfc_interval_str
=
"0"
;
try
{
lfc_interval_str
=
getParameter
(
"lfc-interval"
);
}
catch
(
const
std
::
exception
&
ex
)
{
}
catch
(
const
std
::
exception
&
)
{
// Ignore and default to 0.
}
uint32_t
lfc_interval
=
0
;
try
{
lfc_interval
=
boost
::
lexical_cast
<
uint32_t
>
(
lfc_interval_str
);
}
catch
(
boost
::
bad_lexical_cast
&
ex
)
{
}
catch
(
boost
::
bad_lexical_cast
&
)
{
isc_throw
(
isc
::
BadValue
,
"invalid value of the lfc-interval "
<<
lfc_interval_str
<<
" specified"
);
}
...
...
src/lib/dhcpsrv/parsers/dhcp_parsers.cc
View file @
346b2a28
...
...
@@ -378,7 +378,7 @@ OptionDataParser::extractCode(ConstElementPtr parent) const {
try
{
code
=
uint32_values_
->
getParam
(
"code"
);
}
catch
(
const
exception
&
ex
)
{
}
catch
(
const
exception
&
)
{
// The code parameter was not found. Return an unspecified
// value.
return
(
OptionalValue
<
uint32_t
>
());
...
...
src/lib/dns/rdata.cc
View file @
346b2a28
// 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
...
...
@@ -235,7 +235,7 @@ Generic::constructFromLexer(MasterLexer& lexer) {
try
{
rdlen
=
lexer
.
getNextToken
(
MasterToken
::
NUMBER
).
getNumber
();
}
catch
(
const
MasterLexer
::
LexerError
&
ex
)
{
}
catch
(
const
MasterLexer
::
LexerError
&
)
{
isc_throw
(
InvalidRdataLength
,
"Unknown RDATA length is invalid"
);
}
...
...
src/lib/log/tests/logger_lock_test.cc
View file @
346b2a28
// Copyright (C) 2012 Internet Systems Consortium, Inc. ("ISC")
// Copyright (C) 2012
, 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
...
...
@@ -40,7 +40,7 @@ protected:
try
{
// This lock attempt is non-blocking.
Mutex
::
Locker
locker
(
LoggerManager
::
getMutex
(),
false
);
}
catch
(
Mutex
::
Locker
::
AlreadyLocked
&
e
)
{
}
catch
(
Mutex
::
Locker
::
AlreadyLocked
&
)
{
cout
<<
"FIELD1 FIELD2 LOGGER_LOCK_TEST: MUTEXLOCK
\n
"
;
}
...
...
src/lib/util/csv_file.cc
View file @
346b2a28
...
...
@@ -195,7 +195,7 @@ CSVFile::size() const {
fs
.
seekg
(
0
,
std
::
ifstream
::
end
);
pos
=
fs
.
tellg
();
fs
.
close
();
}
catch
(
const
std
::
exception
&
ex
)
{
}
catch
(
const
std
::
exception
&
)
{
return
(
0
);
}
return
(
pos
);
...
...
@@ -321,7 +321,7 @@ CSVFile::open(const bool seek_to_end) {
fs_
->
clear
();
}
}
catch
(
const
std
::
exception
&
ex
)
{
}
catch
(
const
std
::
exception
&
)
{
close
();
throw
;
}
...
...
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