summaryrefslogtreecommitdiffstats
path: root/vm/Sync.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'vm/Sync.cpp')
-rw-r--r--vm/Sync.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/vm/Sync.cpp b/vm/Sync.cpp
index 8a3803eb4..810107d6c 100644
--- a/vm/Sync.cpp
+++ b/vm/Sync.cpp
@@ -276,6 +276,11 @@ static void logContentionEvent(Thread *self, u4 waitMs, u4 samplePercent,
size_t len;
int fd;
+ /* When a thread is being destroyed it is normal that the frame depth is zero */
+ if (self->interpSave.curFrame == NULL) {
+ return;
+ }
+
saveArea = SAVEAREA_FROM_FP(self->interpSave.curFrame);
meth = saveArea->method;
cp = eventBuffer;