Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBeat Schwarzentrub2018-10-18 08:18:49 +0000
committerBeat Schwarzentrub2018-10-18 08:52:37 +0000
commit621cf73476c0f581752fde4752f1a0cbd88e0a29 (patch)
tree183cf4ac7508984ce8a0b81e8f1536c833cda56e
parent22518e623db952df6aa55b6ac88924a55794a69c (diff)
downloadorg.eclipse.scout.rt-621cf73476c0f581752fde4752f1a0cbd88e0a29.tar.gz
org.eclipse.scout.rt-621cf73476c0f581752fde4752f1a0cbd88e0a29.tar.xz
org.eclipse.scout.rt-621cf73476c0f581752fde4752f1a0cbd88e0a29.zip
MinifyJsWithYui: prevent NPE, instead throw EvaluatorException with msg
Returning null in the Mozilla error reporter causes a NullPointerException, because the Parser will throw the returned value. Returning an new EvaluatorException instance does not work either (for some unknown reason it causes a NPE as well). Solution: throw EvaluatorException directly. Change-Id: I9f21635fd14196698f76bfd5f2cfb91f082f5982 Reviewed-on: https://git.eclipse.org/r/131110 Tested-by: CI Bot Reviewed-by: Beat Schwarzentrub <bsh@bsiag.com>
-rw-r--r--org.eclipse.scout.rt.ui.html.scriptprocessor/src/main/java/org/eclipse/scout/rt/ui/html/scriptprocessor/internal/impl/MinifyJsWithYui.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/org.eclipse.scout.rt.ui.html.scriptprocessor/src/main/java/org/eclipse/scout/rt/ui/html/scriptprocessor/internal/impl/MinifyJsWithYui.java b/org.eclipse.scout.rt.ui.html.scriptprocessor/src/main/java/org/eclipse/scout/rt/ui/html/scriptprocessor/internal/impl/MinifyJsWithYui.java
index 0fce5ea05b..196220c568 100644
--- a/org.eclipse.scout.rt.ui.html.scriptprocessor/src/main/java/org/eclipse/scout/rt/ui/html/scriptprocessor/internal/impl/MinifyJsWithYui.java
+++ b/org.eclipse.scout.rt.ui.html.scriptprocessor/src/main/java/org/eclipse/scout/rt/ui/html/scriptprocessor/internal/impl/MinifyJsWithYui.java
@@ -41,7 +41,7 @@ public class MinifyJsWithYui {
@Override
public EvaluatorException runtimeError(String message, String sourceName, int line, String lineSource, int lineOffset) {
System.out.println(MinifyJsWithYui.class.getSimpleName() + " error: " + message);
- return null;
+ throw new EvaluatorException(message, sourceName, line, lineSource, lineOffset);
}
@Override

Back to the top