Ignore:
Timestamp:
2011-08-25T22:04:29+12:00 (13 years ago)
Author:
ak19
Message:

When do not modify port is selected, it displays an error message and does nothing until you hit the restart button.

File:
1 edited

Legend:

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

    r24465 r24479  
    301301    }
    302302
    303     public void reloadConfigProperties(boolean port_has_changed) {
     303    public boolean reloadConfigProperties(boolean port_has_changed) {
    304304    super.reloadConfigProperties(port_has_changed);
    305305
     
    318318        if(!PortFinder.isPortAvailable(portNum, verbose)) { // first time, print any Port Unavailable messages
    319319        if(keepport.equals("1")) {
    320             String errorMsg = "Unable to run the Greenstone server on port " + port + ". It may already be in use.";
     320            server_control_.errorMessage(dictionary.get("ServerSettings.SettingsUnchangedPortOccupied", new String[]{port}));
     321            String errorMsg = "Unable to run the Greenstone server on port " + port + ". It appears to already be in use.";
    321322            System.err.println("\n******************");
    322             logger_.error(errorMsg);
     323            logger_.error(errorMsg);
    323324            System.err.println("If you wish to try another port, go to File > Settings of the Greenstone Server interface and either change the port number or untick the \"Do Not Modify Port\" option there. Then press the \"Enter Library\" button.");
    324325            System.err.println("******************\n");
     326           
     327            return false; // property change is unsuccessful
     328           
    325329        } else { // can modify port, try to find a new port
    326330       
     
    355359    }
    356360   
     361    return true;
    357362    }
    358363
Note: See TracChangeset for help on using the changeset viewer.