db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d..@apache.org
Subject svn commit: r511121 - /db/derby/code/trunk/java/engine/org/apache/derby/impl/store/raw/data/CachedPage.java
Date Fri, 23 Feb 2007 21:52:11 GMT
Author: djd
Date: Fri Feb 23 13:52:10 2007
New Revision: 511121

URL: http://svn.apache.org/viewvc?view=rev&rev=511121
Log:
Improve comment in CachedPage.setPageArray() about garbage collection order.

Modified:
    db/derby/code/trunk/java/engine/org/apache/derby/impl/store/raw/data/CachedPage.java

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/store/raw/data/CachedPage.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/store/raw/data/CachedPage.java?view=diff&rev=511121&r1=511120&r2=511121
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/store/raw/data/CachedPage.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/store/raw/data/CachedPage.java Fri
Feb 23 13:52:10 2007
@@ -849,16 +849,17 @@
 		containerRowCount = rowCount;
 	}
 
-	/*
+	/**
 	** if the page size is different from the page buffer, then make a
 	** new page buffer and make subclass use the new page buffer
 	*/
-
 	protected void setPageArray(int pageSize)
 	{
 		if ((pageData == null) || (pageData.length != pageSize)) 
         {
-            // Give a chance for gc to release the old buffer
+            // Give a chance for garbage collection to free
+            // the old array before the new array is allocated.
+            // Just in case memory is low.
             pageData = null; 
 			pageData = new byte[pageSize];
 				



Mime
View raw message