diff options
author | Benoit Foucher <benoit@zeroc.com> | 2005-02-07 08:23:48 +0000 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2005-02-07 08:23:48 +0000 |
commit | 059a83dca0bc2736e12adf24ab34149319fbc1c8 (patch) | |
tree | 485e15ec5eac49700c7bd8ac1ce9f7d18a09d6a2 /cpp/src/Ice/LocatorInfo.cpp | |
parent | improved demo (diff) | |
download | ice-059a83dca0bc2736e12adf24ab34149319fbc1c8.tar.bz2 ice-059a83dca0bc2736e12adf24ab34149319fbc1c8.tar.xz ice-059a83dca0bc2736e12adf24ab34149319fbc1c8.zip |
Fixed bug in locator info cache
Diffstat (limited to 'cpp/src/Ice/LocatorInfo.cpp')
-rw-r--r-- | cpp/src/Ice/LocatorInfo.cpp | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/cpp/src/Ice/LocatorInfo.cpp b/cpp/src/Ice/LocatorInfo.cpp index a99a1c163c3..4cc7e7a76a4 100644 --- a/cpp/src/Ice/LocatorInfo.cpp +++ b/cpp/src/Ice/LocatorInfo.cpp @@ -383,13 +383,22 @@ IceInternal::LocatorInfo::clearObjectCache(const IndirectReferencePtr& ref) if(ref->getAdapterId().empty()) { ObjectPrx object = _table->removeProxy(ref->getIdentity()); - - if(ref->getInstance()->traceLevels()->location >= 2 && object) + if(object) { - vector<EndpointPtr> endpoints = object->__reference()->getEndpoints(); - if(!endpoints.empty()) + IndirectReferencePtr oir = IndirectReferencePtr::dynamicCast(object->__reference()); + if(oir) { - trace("removed endpoints from locator table", ref, endpoints); + if(!oir->getAdapterId().empty()) + { + clearCache(oir); + } + } + else + { + if(ref->getInstance()->traceLevels()->location >= 2) + { + trace("removed endpoints from locator table", ref, object->__reference()->getEndpoints()); + } } } } |