Return-Path: Delivered-To: apmail-xml-cocoon-cvs-archive@xml.apache.org Received: (qmail 7156 invoked by uid 500); 15 Jan 2003 12:28:18 -0000 Mailing-List: contact cocoon-cvs-help@xml.apache.org; run by ezmlm Precedence: bulk Reply-To: cocoon-dev@xml.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list cocoon-cvs@xml.apache.org Received: (qmail 7127 invoked by uid 500); 15 Jan 2003 12:28:18 -0000 Delivered-To: apmail-xml-cocoon2-cvs@apache.org Date: 15 Jan 2003 12:28:18 -0000 Message-ID: <20030115122818.97744.qmail@icarus.apache.org> From: cziegeler@apache.org To: xml-cocoon2-cvs@apache.org Subject: cvs commit: xml-cocoon2/src/java/org/apache/cocoon/components/pipeline/impl AbstractCachingProcessingPipeline.java CachingProcessingPipeline.java X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N cziegeler 2003/01/15 04:28:17 Modified: src/java/org/apache/cocoon/components/pipeline/impl AbstractCachingProcessingPipeline.java CachingProcessingPipeline.java Log: Fixing NPE in caching algorithm Revision Changes Path 1.22 +5 -1 xml-cocoon2/src/java/org/apache/cocoon/components/pipeline/impl/AbstractCachingProcessingPipeline.java Index: AbstractCachingProcessingPipeline.java =================================================================== RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/components/pipeline/impl/AbstractCachingProcessingPipeline.java,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- AbstractCachingProcessingPipeline.java 15 Jan 2003 11:52:33 -0000 1.21 +++ AbstractCachingProcessingPipeline.java 15 Jan 2003 12:28:17 -0000 1.22 @@ -586,6 +586,10 @@ } i++; } + } else { + // we don't have to cache + this.toCacheKey = null; + this.cacheCompleteResponse = false; } } } 1.33 +1 -5 xml-cocoon2/src/java/org/apache/cocoon/components/pipeline/impl/CachingProcessingPipeline.java Index: CachingProcessingPipeline.java =================================================================== RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/components/pipeline/impl/CachingProcessingPipeline.java,v retrieving revision 1.32 retrieving revision 1.33 diff -u -r1.32 -r1.33 --- CachingProcessingPipeline.java 15 Jan 2003 12:04:51 -0000 1.32 +++ CachingProcessingPipeline.java 15 Jan 2003 12:28:17 -0000 1.33 @@ -81,10 +81,6 @@ */ protected void cacheResults(Environment environment, OutputStream os) throws Exception { if (this.toCacheKey != null) { - if (this.toCacheSourceValidities == null) { - getLogger().warn("CACHING-ERROR: Cache key is not null:"+this.toCacheKey+"\nbut sourcevalidities!"); - return; - } if ( this.cacheCompleteResponse ) { CachedResponse response = new CachedResponse(this.toCacheSourceValidities, ((CachingOutputStream)os).getContent()); ---------------------------------------------------------------------- In case of troubles, e-mail: webmaster@xml.apache.org To unsubscribe, e-mail: cocoon-cvs-unsubscribe@xml.apache.org For additional commands, e-mail: cocoon-cvs-help@xml.apache.org