From: helge Date: Fri, 22 Jul 2005 13:02:52 +0000 (+0000) Subject: improved etag check X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0d08222e08c83a8454a970c2a3d7283a740d6b83;p=sope improved etag check git-svn-id: http://svn.opengroupware.org/SOPE/trunk@933 e4a50df8-12e2-0310-a44c-efbce7f8a7e3 --- diff --git a/sope-appserver/NGObjWeb/SoObjects/SoObject+Traversal.m b/sope-appserver/NGObjWeb/SoObjects/SoObject+Traversal.m index 9e03a01c..371e8bbe 100644 --- a/sope-appserver/NGObjWeb/SoObjects/SoObject+Traversal.m +++ b/sope-appserver/NGObjWeb/SoObjects/SoObject+Traversal.m @@ -157,6 +157,12 @@ static BOOL _isDebugOn(void) { error:(NSException **)_error acquire:(BOOL)_acquire { + // TODO: We might want to have an addition method to traverse a path without + // modifying the context (for internal lookups). + // Currently most code uses -lookupName:inContext:acquire: directly, + // which doesn't check permissions. + // Note: You can also use SoSubContext to accomplish that, but this is not + // very convenient. register BOOL doDebug = _isDebugOn(); WORequest *rq; BOOL isCreateIfMissingMethod = NO; diff --git a/sope-appserver/WEPrototype/ChangeLog b/sope-appserver/WEPrototype/ChangeLog index 74eebfc8..73c9b986 100644 --- a/sope-appserver/WEPrototype/ChangeLog +++ b/sope-appserver/WEPrototype/ChangeLog @@ -1,3 +1,8 @@ +2005-07-22 Helge Hess + + * WEPrototypeScriptAction.m: improved check of if-none-match header + (v4.5.4) + 2005-07-14 Helge Hess * added Scriptaculous library v1.0.0 (v4.5.3) diff --git a/sope-appserver/WEPrototype/Version b/sope-appserver/WEPrototype/Version index 8304a6a3..c6652eb6 100644 --- a/sope-appserver/WEPrototype/Version +++ b/sope-appserver/WEPrototype/Version @@ -1,5 +1,5 @@ # version file -SUBMINOR_VERSION:=3 +SUBMINOR_VERSION:=4 # v4.5.1 requires libNGObjWeb v4.5.170 diff --git a/sope-appserver/WEPrototype/WEPrototypeScriptAction.m b/sope-appserver/WEPrototype/WEPrototypeScriptAction.m index 7d98b2f3..126c1da5 100644 --- a/sope-appserver/WEPrototype/WEPrototypeScriptAction.m +++ b/sope-appserver/WEPrototype/WEPrototypeScriptAction.m @@ -51,11 +51,12 @@ static NSString *script = /* check preconditions */ - s = [[[self context] request] headerForKey:@"if-none-match"]; - if ([s rangeOfString:etag].length > 0) { - /* client already has the proper entity */ - [r setStatus:304 /* Not Modified */]; - return r; + if ((s = [[[self context] request] headerForKey:@"if-none-match"]) != nil) { + if ([s rangeOfString:etag].length > 0) { + /* client already has the proper entity */ + [r setStatus:304 /* Not Modified */]; + return r; + } } /* send script */