Changeset 1268 for trunk


Ignore:
Timestamp:
07/25/13 15:08:58 (11 years ago)
Author:
pharms
Message:
  • removed find bugs warnings
Location:
trunk/autoquest-htmlmonitor/src/main/java/de/ugoe/cs/autoquest/htmlmonitor
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/autoquest-htmlmonitor/src/main/java/de/ugoe/cs/autoquest/htmlmonitor/HtmlMonitorOutputWriter.java

    r1249 r1268  
    415415     * </p> 
    416416     * 
    417      * @param file 
    418      * @param clientLogDir 
     417     * @param oldLogDir the old log directory 
     418     * @param newLogDir the new log directory 
    419419     */ 
    420420    private void handleOldLogFiles(File oldLogDir, File newLogDir) { 
    421421        if (oldLogDir.exists() && oldLogDir.isDirectory()) { 
     422            boolean allFilesRenamed = true; 
    422423            for (File oldLogFile : oldLogDir.listFiles()) { 
    423                 oldLogFile.renameTo(new File(newLogDir, oldLogFile.getName())); 
     424                allFilesRenamed &= oldLogFile.renameTo(new File(newLogDir, oldLogFile.getName())); 
    424425            } 
    425426             
    426             oldLogDir.delete(); 
     427            if (allFilesRenamed) { 
     428                if (!oldLogDir.delete()) { 
     429                    Console.printerrln("could not move old file directory structure to new one"); 
     430                } 
     431            } 
    427432        } 
    428433    } 
  • trunk/autoquest-htmlmonitor/src/main/java/de/ugoe/cs/autoquest/htmlmonitor/HtmlMonitorServlet.java

    r1233 r1268  
    2424import java.net.URL; 
    2525import java.util.ArrayList; 
     26import java.util.Arrays; 
    2627import java.util.List; 
    2728import java.util.Map; 
     
    554555        if (!result) { 
    555556            Console.printerrln(eventType + " event has invalid parameters"); 
    556             Console.printerrln("coordinates: " + coordinates); 
     557            Console.printerrln("coordinates: " + Arrays.toString(coordinates)); 
    557558            Console.printerrln("key: " + key); 
    558             Console.printerrln("scrollPosition: " + scrollPosition); 
     559            Console.printerrln("scrollPosition: " + Arrays.toString(scrollPosition)); 
    559560            Console.printerrln("selectedValue: " + selectedValue); 
    560561        } 
Note: See TracChangeset for help on using the changeset viewer.