Commit b9fd2417 authored by Robert Butora's avatar Robert Butora
Browse files

mcutout: fixes type cast

parent 5d3a8471
Loading
Loading
Loading
Loading
+34 −22
Original line number Diff line number Diff line
@@ -68,7 +68,14 @@ public class UWSMCutoutWork extends JobThread
         long startTime_msec = System.currentTimeMillis();
         boolean showDuration = true;

         UploadFile jsonFile = (UploadFile)job.getAdditionalParameterValue("mcutout");
			logger.logThread(LogLevel.INFO, this, "Is mcutout UploadFile type?",
															"Is mcutout UploadFile type?",null);
         Object obj = job.getAdditionalParameterValue("mcutout");
			if(obj instanceof UploadFile)
			{
			   logger.logThread(LogLevel.INFO, this, "mcutout is UploadFile",
														"mcutout is UploadFile",null);
				UploadFile jsonFile = (UploadFile)obj;//job.getAdditionalParameterValue("mcutout");

				InputStreamReader isr = new InputStreamReader(jsonFile.open());
				BufferedReader input = new BufferedReader(isr);
@@ -98,6 +105,11 @@ public class UWSMCutoutWork extends JobThread

				FileUtils.deleteDirectory(new File(workDir));
				//FileUtils.deleteQuietly(new File(workDir));// FIXME Never throws except. leaves the dir there if error
			}
			else
			{
              // mcutout-json not in body
			}

			/* FIXME here was uws-check is-job-Interrupted */
		}