aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/lint/EclipseLintClient.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/lint/EclipseLintClient.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/lint/EclipseLintClient.java
index fd8125e..54222e3 100644
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/lint/EclipseLintClient.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/lint/EclipseLintClient.java
@@ -913,7 +913,12 @@ public class EclipseLintClient extends LintClient {
@Override
@NonNull
public IAndroidTarget[] getTargets() {
- return Sdk.getCurrent().getTargets();
+ Sdk sdk = Sdk.getCurrent();
+ if (sdk != null) {
+ return sdk.getTargets();
+ } else {
+ return new IAndroidTarget[0];
+ }
}
private boolean mSearchForSuperClasses;