You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by do...@apache.org on 2010/01/27 20:50:17 UTC
svn commit: r903799 -
/ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/ConfigXMLReader.java
Author: doogie
Date: Wed Jan 27 19:50:17 2010
New Revision: 903799
URL: http://svn.apache.org/viewvc?rev=903799&view=rev
Log:
Fix for a memory leak; sometime during the past, the initial url fetched
from the servlet container started being a jndi:// form; so, when
include processing was introduced, the urls wouldn't match up. Instead,
implement a temporary hack to convert the servlet path to a file, so
that the urls will be normalized.
Modified:
ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/ConfigXMLReader.java
Modified: ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/ConfigXMLReader.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/ConfigXMLReader.java?rev=903799&r1=903798&r2=903799&view=diff
==============================================================================
--- ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/ConfigXMLReader.java (original)
+++ ofbiz/trunk/framework/webapp/src/org/ofbiz/webapp/control/ConfigXMLReader.java Wed Jan 27 19:50:17 2010
@@ -56,7 +56,7 @@
public static URL getControllerConfigURL(ServletContext context) {
try {
- return context.getResource(controllerXmlFileName);
+ return new File(context.getRealPath(controllerXmlFileName)).toURI().toURL();
} catch (MalformedURLException e) {
Debug.logError(e, "Error Finding XML Config File: " + controllerXmlFileName, module);
return null;