Avoid NPE when GEOSERVER_DATA_DIR points to an empty directory
--------------------------------------------------------------
Key: GEOS-1754
URL: http://jira.codehaus.org/browse/GEOS-1754
Project: GeoServer
Issue Type: Bug
Affects Versions: 1.6.0
Reporter: Andrea Aime
Assignee: Andrea Aime
Fix For: 1.6.1, 1.7.0-beta1
If a user points the data dir to an emtpy directory the result will be something like:
{code}
19 Feb 08:05:11 ERROR [context.ContextLoader] - Context initialization
failed
org.springframework.beans.factory.BeanCreationException: Error creating bean
wit
h name 'config' defined in URL
[jar:file:/C:/Program%20Files/GeoServer%201.6.0/w
tion of bean failed; nested exception is java.lang.NullPointerException:
null
ebapps/geoserver/WEB-INF/lib/main-1.6.0.jar!/applicationContext.xml]:
Initializa
java.lang.NullPointerException
at java.io.FileInputStream.<init>(FileInputStream.java:103)
at
org.vfny.geoserver.global.xml.XMLConfigReader.loadServices(XMLConfigR
eader.java:253)
at
org.vfny.geoserver.global.xml.XMLConfigReader.load(XMLConfigReader.ja
va:214)
at
org.vfny.geoserver.global.xml.XMLConfigReader.<init>(XMLConfigReader.
java:176)
at
...
{code}
We need to tell the user the data dir is not valid instead (or eventually unpack a bare bones one in that location to compensate)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira