Index: pkg/analysis_server/lib/src/status/memory_use.dart |
diff --git a/pkg/analysis_server/lib/src/status/memory_use.dart b/pkg/analysis_server/lib/src/status/memory_use.dart |
index 92657bcdc0454cfa26f3bdda521d0e47d9632b0f..8f68b0f37bdee06d4b6ea4e8066a0fc3f521eff5 100644 |
--- a/pkg/analysis_server/lib/src/status/memory_use.dart |
+++ b/pkg/analysis_server/lib/src/status/memory_use.dart |
@@ -225,8 +225,10 @@ class MemoryUseData { |
DartSdkManager manager = server.sdkManager; |
List<SdkDescription> descriptors = manager.sdkDescriptors; |
for (SdkDescription descriptor in descriptors) { |
- _processAnalysisContext( |
- manager.getSdk(descriptor, () => null).context, manager); |
+ DartSdk sdk = manager.getSdk(descriptor, () => null); |
+ if (sdk != null) { |
+ _processAnalysisContext(sdk.context, manager); |
+ } |
} |
} |