From: Marcin Siodelski Date: Tue, 29 Sep 2015 17:55:27 +0000 (+0200) Subject: [3971] Addressed other review comments. X-Git-Tag: trac4074_base~11^2~1 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=fa0f966cf5f1305066858050fb7b8caa4cb8a4f8;p=thirdparty%2Fkea.git [3971] Addressed other review comments. --- diff --git a/src/lib/dhcpsrv/tests/memfile_lease_mgr_unittest.cc b/src/lib/dhcpsrv/tests/memfile_lease_mgr_unittest.cc index 801d1fd39b..d67e83c6c1 100644 --- a/src/lib/dhcpsrv/tests/memfile_lease_mgr_unittest.cc +++ b/src/lib/dhcpsrv/tests/memfile_lease_mgr_unittest.cc @@ -356,9 +356,7 @@ TEST_F(MemfileLeaseMgrTest, lfcTimer) { // Run the test for at most 2.9 seconds. setTestTime(2900); - // Stop worker thread to make sure it is not running when lease - // manager is destroyed. The lease manager will be unable to - // unregster timer when the thread is active. + // Stop worker thread. ASSERT_NO_THROW(timer_mgr_->stopThread()); // Within 2.9 we should record two LFC executions. diff --git a/src/lib/testutils/dhcp_test_lib.sh.in b/src/lib/testutils/dhcp_test_lib.sh.in index b3e7602814..6e20791707 100644 --- a/src/lib/testutils/dhcp_test_lib.sh.in +++ b/src/lib/testutils/dhcp_test_lib.sh.in @@ -250,7 +250,9 @@ cleanup() { # Use asterisk to remove all files starting with the given name, # in case the LFC has been run. LFC creates files with postfixes # appended to the lease file name. - rm -rf ${LEASE_FILE}* + if [ ! -z "${LEASE_FILE}" ]; then + rm -rf ${LEASE_FILE}* + fi rm -rf ${CFG_FILE} rm -rf ${KEACTRL_CFG_FILE} }