Commit in lcsim/src/org/lcsim/job on MAIN
JobControlManager.java+121.40 -> 1.41
Added check for line breaks in file names. Happens in badly formated XMLs.

lcsim/src/org/lcsim/job
JobControlManager.java 1.40 -> 1.41
diff -u -r1.40 -r1.41
--- JobControlManager.java	21 May 2010 17:44:48 -0000	1.40
+++ JobControlManager.java	27 May 2010 13:01:29 -0000	1.41
@@ -505,6 +505,18 @@
 		    }
 		}
 		
+		// Check that there are no line breaks and no trailing white spaces in file names
+		for (File file : inputFiles) {
+			String filePath = file.getAbsolutePath();
+			if (filePath.contains(System.getProperty("line.separator")) || filePath.contains(" ")) {
+				filePath = filePath.replace(System.getProperty("line.separator"), "");
+				filePath = filePath.replaceAll("\\s+$", "");
+				inputFiles.remove(file);
+				File newFile = new File(filePath);
+				inputFiles.add(newFile);
+			}
+		}
+		
 		// Check that all files exist.
 		for (File file : inputFiles)
         {
CVSspam 0.2.8