From 88d462afd3923b8a064a47bf5639a69618d38255 Mon Sep 17 00:00:00 2001 From: Scott Cantor Date: Sat, 10 Mar 2007 21:56:01 +0000 Subject: [PATCH] Return expiration on versioned read. --- xmltooling/impl/MemoryStorageService.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xmltooling/impl/MemoryStorageService.cpp b/xmltooling/impl/MemoryStorageService.cpp index 697c55e..9fd63be 100644 --- a/xmltooling/impl/MemoryStorageService.cpp +++ b/xmltooling/impl/MemoryStorageService.cpp @@ -247,12 +247,12 @@ int MemoryStorageService::readString(const char* context, const char* key, strin return 0; else if (time(NULL) >= i->second.expiration) return 0; + if (pexpiration) + *pexpiration = i->second.expiration; if (i->second.version == version) return version; // nothing's changed, so just echo back the version if (pvalue) *pvalue = i->second.data; - if (pexpiration) - *pexpiration = i->second.expiration; return i->second.version; } -- 2.1.4