diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2018-11-15 09:18:18 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2018-11-15 09:18:48 +0100 |
commit | 70555d532df7ab185c41d5589b2aa2b77f18ceca (patch) | |
tree | 9cac3626dcaf2d03b64503bebfc71445bc2d228f | |
parent | 9f2c3ceebe191c008f004bd8dba39ebc56df51ee (diff) |
mutex: Avoid NULL pointer access in panic()
-rw-r--r-- | rtemsbsd/include/machine/rtems-bsd-muteximpl.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/rtemsbsd/include/machine/rtems-bsd-muteximpl.h b/rtemsbsd/include/machine/rtems-bsd-muteximpl.h index c947e2ba..b362e524 100644 --- a/rtemsbsd/include/machine/rtems-bsd-muteximpl.h +++ b/rtemsbsd/include/machine/rtems-bsd-muteximpl.h @@ -201,7 +201,8 @@ rtems_bsd_mutex_unlock(rtems_bsd_mutex *m) rtems_bsd_mutex_release(m, isr_level, &queue_context); panic("mutex unlock: %s: owner 0x%08" PRIx32 " != executing 0x%08" PRIx32 "\n", m->queue.Queue.name, - owner->Object.id, executing->Object.id); + owner != NULL ? owner->Object.id : 0, + executing->Object.id); } if (__predict_true(nest_level == 0)) { |