Changeset 18696

Show
Ignore:
Timestamp:
16.03.2009 19:01:41 (10 years ago)
Author:
ak19
Message:

Fixed bug on saving settings in GS2.

Location:
greenstone3/trunk/src/java/org/greenstone/server
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • greenstone3/trunk/src/java/org/greenstone/server/BaseServerSettings.java

    r18693 r18696  
    7171        this.autoStart = false; 
    7272    } 
    73  
    74     this.servletDefault = server.build_properties.getProperty(BaseServer.Property.DEFAULT_SERVLET).replaceAll("/",""); 
    7573 
    7674    setSize(SIZE); 
     
    240238                has_changed = true; 
    241239        } 
    242         if (!servletDefault.equals(servlet_combobox.getSelectedItem())) { 
    243             has_changed = true; 
    244                 require_restart = true;  
     240        if(servletDefault != null && servlet_combobox != null) { 
     241        if (!servletDefault.equals(servlet_combobox.getSelectedItem())) { 
     242            has_changed = true; 
     243            require_restart = true;  
     244        } 
    245245        } 
    246246            //changed to use other browser 
     
    281281            browserPath = browserPath.replaceAll("\\\\","/"); 
    282282        } 
    283                  newFileLines = scriptReadWrite.queryReplace(newFileLines,BaseServer.Property.BROWSER_PATH, browserPath); 
     283        newFileLines = scriptReadWrite.queryReplace(newFileLines,BaseServer.Property.BROWSER_PATH, browserPath); 
    284284 
    285285        scriptReadWrite.writeOutFile(BaseServer.build_properties_file, 
  • greenstone3/trunk/src/java/org/greenstone/server/Server3Settings.java

    r18693 r18696  
    2222    { 
    2323    super(server); 
     24    this.servletDefault = server.build_properties.getProperty(BaseServer.Property.DEFAULT_SERVLET).replaceAll("/",""); 
    2425    } 
    2526