aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaphael <raphael@google.com>2010-03-29 16:35:19 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2010-03-29 16:35:19 -0700
commit93338ae695855f6a4acf41a1e614a2a711d94524 (patch)
treec630d87bdeddc78f148eb5e19faf100a4be84615
parentd2db734426958e3db4ec8fe220caf86a76c4049c (diff)
parent83901b95bf538ba3730877528224a3cda4117ffb (diff)
downloadsdk-93338ae695855f6a4acf41a1e614a2a711d94524.zip
sdk-93338ae695855f6a4acf41a1e614a2a711d94524.tar.gz
sdk-93338ae695855f6a4acf41a1e614a2a711d94524.tar.bz2
Merge "ADT: Fix NPE when opening a project-library." into tools-r6
-rw-r--r--eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/project/ProjectState.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/project/ProjectState.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/project/ProjectState.java
index 8c08baf..11cbc15 100644
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/project/ProjectState.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/project/ProjectState.java
@@ -371,7 +371,8 @@ public final class ProjectState {
public LibraryState getLibrary(String name) {
synchronized (mLibraries) {
for (LibraryState state : mLibraries) {
- if (state.getProjectState().getProject().getName().equals(name)) {
+ ProjectState ps = state.getProjectState();
+ if (ps != null && ps.getProject().getName().equals(name)) {
return state;
}
}