From 4a15c2a105035ffcdbf804254a9caa1e8779dbad Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Sun, 24 Jun 2012 04:52:01 -0700 Subject: [PATCH] Bugfix. --- src/TaggedCache.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/TaggedCache.h b/src/TaggedCache.h index a53b7d3dc5..8c84a34654 100644 --- a/src/TaggedCache.h +++ b/src/TaggedCache.h @@ -121,7 +121,7 @@ template bool TaggedCache::touch // Is the object in the map? typename boost::unordered_map::iterator mit = mMap.find(key); if (mit == mMap.end()) return false; - if (mit->second->expired()) + if (mit->second.expired()) { // in map, but expired mMap.erase(mit); return false; @@ -131,12 +131,12 @@ template bool TaggedCache::touch typename boost::unordered_map::iterator cit = mCache.find(key); if (cit != mCache.end()) { // in both map and cache - cit->second->first = time(NULL); + cit->second.first = time(NULL); return true; } // In map but not cache, put in cache - mCache.insert(std::make_pair(key, std::make_pair(time(NULL), weak_data_ptr(cit->second->second)))); + mCache.insert(std::make_pair(key, std::make_pair(time(NULL), weak_data_ptr(cit->second.second)))); return true; }