commit | aac308c1f0b0778a3092209827232778894d5fc9 | [log] [tgz] |
---|---|---|
author | bchilds <bchilds> | Fri Nov 21 20:17:27 2008 +0000 |
committer | bchilds <bchilds> | Fri Nov 21 20:17:27 2008 +0000 |
tree | 96c2a7a9b41522e9d41f25fc8a0aba32471dca30 | |
parent | aa85bc48471be84b9d9602a4280adca2562868ce [diff] |
fix for 244839 NPE when opening JS file outside workspace.
diff --git a/bundles/org.eclipse.wst.jsdt.web.core/src/org/eclipse/wst/jsdt/web/core/javascript/JsTranslation.java b/bundles/org.eclipse.wst.jsdt.web.core/src/org/eclipse/wst/jsdt/web/core/javascript/JsTranslation.java index dd82b49..b18fe9d 100644 --- a/bundles/org.eclipse.wst.jsdt.web.core/src/org/eclipse/wst/jsdt/web/core/javascript/JsTranslation.java +++ b/bundles/org.eclipse.wst.jsdt.web.core/src/org/eclipse/wst/jsdt/web/core/javascript/JsTranslation.java
@@ -255,6 +255,11 @@ * @see org.eclipse.wst.jsdt.web.core.internal.java.IJsTranslation#getCompilationUnit() */ public IJavaScriptUnit getCompilationUnit() { + // Genuitec Begin Fix 6149: Exception opening external HTML file + if (!getJavaProject().exists()) { + return null; + } + // Genuitec End Fix 6149: Exception opening external HTML file synchronized (fLock) { try { if (fCompilationUnit == null) {