aboutsummaryrefslogtreecommitdiff
path: root/spark-common
diff options
context:
space:
mode:
authorLuck <git@lucko.me>2022-11-16 21:35:14 +0000
committerLuck <git@lucko.me>2022-11-16 21:35:14 +0000
commitd12f13f7e3024c632f181473711290c88de8cfde (patch)
tree5349401199cbf269a4e8856f3a4f6550bad40e11 /spark-common
parent59e6a9814a357162409b096300dd69f7db58f8bf (diff)
downloadspark-d12f13f7e3024c632f181473711290c88de8cfde.tar.gz
spark-d12f13f7e3024c632f181473711290c88de8cfde.tar.bz2
spark-d12f13f7e3024c632f181473711290c88de8cfde.zip
Fix NPE from null thread name (#263)
Diffstat (limited to 'spark-common')
-rw-r--r--spark-common/src/main/java/me/lucko/spark/common/sampler/async/AsyncProfilerJob.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/spark-common/src/main/java/me/lucko/spark/common/sampler/async/AsyncProfilerJob.java b/spark-common/src/main/java/me/lucko/spark/common/sampler/async/AsyncProfilerJob.java
index 8991e94..1310e97 100644
--- a/spark-common/src/main/java/me/lucko/spark/common/sampler/async/AsyncProfilerJob.java
+++ b/spark-common/src/main/java/me/lucko/spark/common/sampler/async/AsyncProfilerJob.java
@@ -250,6 +250,10 @@ public class AsyncProfilerJob {
}
String threadName = reader.threads.get(sample.tid);
+ if (threadName == null) {
+ continue;
+ }
+
if (!threadFilter.test(threadName)) {
continue;
}