Changeset 9054


Ignore:
Timestamp:
2005-02-16T11:35:39+13:00 (19 years ago)
Author:
mdewsnip
Message:

Removed the unused CTRLCHandler class.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/Gatherer.java

    r9045 r9054  
    111111    }
    112112
     113
    113114    public Gatherer()
    114115    {
     
    125126               String wget_version_str, String wget_path)
    126127    {
    127     // This will hopefully catch ctrl-c and terminate, and exit gracefully. However it is platform specific, and may not be supported by some JVMs.
    128     /** It does, but I get bloody sick of it working when the Gatherer hangs.
    129         CTRLCHandler handler = new CTRLCHandler();
    130         Signal.handle(new Signal("INT"), handler);
    131         Signal.handle(new Signal("TERM"), handler);
    132         handler = null;
    133     */
    134128    if (gsdl3_path != null && !gsdl3_path.equals("")) {
    135129        this.GS3 = true;
     
    137131        gsdl3_path = null;
    138132    }
    139     // Create the debug stream only if required.
     133
     134    // Create the debug stream if required
    140135    if (debug_enabled) {
    141136        DebugStream.enableDebugging();
     
    150145        DebugStream.print(System.getProperties());
    151146    }
     147
    152148    try {
    153149        // Load Config
     
    825821    }
    826822
    827     /** This class is intented to detect a specific SIGNAL, in this case SIGINT, and exit properly, rather than letting the Gatherer be interrupted which has the potential to leave erroneous lock files. */
    828 //      private class CTRLCHandler
    829 //      implements SignalHandler {
    830 //      /** <i>true</i> if we ignore any other signals we receive, most likely because we are already dealing with one, <i>false</i> otherwise. */
    831 //      private boolean ignore = false;
    832 //      /** The method called by the system to inform us a signal has occured.
    833 //       * @param sig The <strong>Signal</strong> itself.
    834 //       * @see org.greenstone.gatherer.collection.CollectionManager
    835 //       */
    836 //      public void handle(Signal sig) {
    837 //          if(!ignore) {
    838 //          ignore = true;
    839 //          // handle SIGINT
    840 //          System.out.println("Caught Ctrl-C...");
    841 //          if(c_man != null && c_man.ready()) {
    842 //              c_man.closeCollection();
    843 //          }
    844 //          exit();
    845 //          ignore = false;
    846 //          }
    847 //      }
    848 //      }
    849823
    850824    private class PerlTest {
Note: See TracChangeset for help on using the changeset viewer.