From f8dcd5ca6f55ad49807cf7491c1f153f6158400e Mon Sep 17 00:00:00 2001 From: Pieter Wuille Date: Fri, 6 Apr 2012 18:39:12 +0200 Subject: Use scoped locks instead of CRITICAL_BLOCK --- src/test/util_tests.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/test/util_tests.cpp') diff --git a/src/test/util_tests.cpp b/src/test/util_tests.cpp index 94c0c77a4..db31f4988 100644 --- a/src/test/util_tests.cpp +++ b/src/test/util_tests.cpp @@ -15,14 +15,15 @@ BOOST_AUTO_TEST_CASE(util_criticalsection) CCriticalSection cs; do { - CRITICAL_BLOCK(cs) - break; + LOCK(cs); + break; BOOST_ERROR("break was swallowed!"); } while(0); do { - TRY_CRITICAL_BLOCK(cs) + TRY_LOCK(cs, lockTest); + if (lockTest) break; BOOST_ERROR("break was swallowed!"); -- cgit v1.2.3