diff options
author | Eric Engestrom <[email protected]> | 2019-12-13 17:12:48 +0000 |
---|---|---|
committer | Eric Engestrom <[email protected]> | 2019-12-13 20:20:21 +0000 |
commit | 1a837e803b2cf389d7e176e2460f926a9976e34e (patch) | |
tree | dac7f48e94a17b088ddeda4dc1485841c8360a36 /src/util/simple_mtx.h | |
parent | d600b19640691200df64c2f69d188bf38efd33cc (diff) |
util/simple_mtx: don't set the canary when it can't be checked
Signed-off-by: Eric Engestrom <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/util/simple_mtx.h')
-rw-r--r-- | src/util/simple_mtx.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/util/simple_mtx.h b/src/util/simple_mtx.h index c0cc13b3663..b23c8d2133d 100644 --- a/src/util/simple_mtx.h +++ b/src/util/simple_mtx.h @@ -71,9 +71,11 @@ simple_mtx_init(simple_mtx_t *mtx, ASSERTED int type) } static inline void -simple_mtx_destroy(simple_mtx_t *mtx) +simple_mtx_destroy(ASSERTED simple_mtx_t *mtx) { +#ifndef NDEBUG mtx->val = _SIMPLE_MTX_INVALID_VALUE; +#endif } static inline void |