do not log throwable when rethrow is more likely to be expected (IDEA-110920)

This commit is contained in:
anna
2013-07-25 13:45:20 +02:00
parent 244eaa514c
commit 853ed31001
2 changed files with 7 additions and 2 deletions
@@ -365,7 +365,12 @@ public class GlobalInspectionContextImpl extends GlobalInspectionContextBase imp
});
}
catch (ProcessCanceledException e) {
throw e;
final Throwable cause = e.getCause();
if (cause != null) {
LOG.error("In file: " + file, cause);
} else {
throw e;
}
}
catch (IndexNotReadyException e) {
throw e;
@@ -70,7 +70,7 @@ public class JobLauncherImpl extends JobLauncher {
}
catch (Throwable throwable) {
job.cancel();
LOG.error(throwable);
throw new ProcessCanceledException(throwable);
}
return !job.isCanceled();
}