Skip to content

Commit 4eb92d4

Browse files
committed
rt: Don't access fields on null supervisor task
1 parent f76e6c3 commit 4eb92d4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/rt/rust_task.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -482,11 +482,11 @@ rust_task::fail_parent() {
482482
void
483483
rust_task::unsupervise()
484484
{
485-
DLOG(sched, task,
485+
if (supervisor) {
486+
DLOG(sched, task,
486487
"task %s @0x%" PRIxPTR
487488
" disconnecting from supervisor %s @0x%" PRIxPTR,
488489
name, this, supervisor->name, supervisor);
489-
if (supervisor) {
490490
supervisor->deref();
491491
}
492492
supervisor = NULL;

0 commit comments

Comments
 (0)