From c4bd4a2781acc18a6ea7c5671241ace49d0603d5 Mon Sep 17 00:00:00 2001 From: Steve Huston Date: Thu, 24 May 2012 15:14:20 +0000 Subject: ChangeLogTag:Thu May 24 14:35:04 UTC 2012 Steve Huston --- ChangeLog | 9 +++++++++ ace/Cache_Map_Manager_T.cpp | 2 +- tests/Cache_Map_Manager_Test.cpp | 6 +++++- 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index ed90b505cd3..d5da2cdf64e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +Thu May 24 14:35:04 UTC 2012 Steve Huston + + * ace/Cache_Map_Manager_T.cpp (find): Remove extraneous () from + 'second' - leftover from ACE_Pair days. + + * tests/Cache_Map_Manager_Test.cpp: Add call to the above method. + + * THANKS: Thanks to Milind Pangarkar for the above test, and fix. + Tue Apr 17 17:46:56 EDT 2012 Steve Huston * ACE version 6.0b released. diff --git a/ace/Cache_Map_Manager_T.cpp b/ace/Cache_Map_Manager_T.cpp index 7d27cc9a311..68708524581 100644 --- a/ace/Cache_Map_Manager_T.cpp +++ b/ace/Cache_Map_Manager_T.cpp @@ -323,7 +323,7 @@ ACE_Cache_Map_Manager::find (const KEY &key) { int result = this->caching_strategy_.notify_find (find_result, - cache_value.second ()); + cache_value.second); // Unless the find and notification operations go thru, this // method is not successful. diff --git a/tests/Cache_Map_Manager_Test.cpp b/tests/Cache_Map_Manager_Test.cpp index a23dea8b42d..bc96e726e62 100644 --- a/tests/Cache_Map_Manager_Test.cpp +++ b/tests/Cache_Map_Manager_Test.cpp @@ -241,13 +241,17 @@ find_test_cache (MAP_CACHE &cache) { VALUE j = 0; int result = cache.find (lookup_array[i], j); - + result = cache.find (lookup_array[i]); ACE_ASSERT (result != -1); ACE_ASSERT (j == lookup_array[i]); if (debug) ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%d "), j)); + // Once more, with only the key. Test Bugzilla #4029. + result = cache.find (lookup_array[i]); + ACE_TEST_ASSERT (result != -1); + ACE_UNUSED_ARG (result); } -- cgit v1.2.1