summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Evans <jasone@canonware.com>2017-06-23 17:40:02 (GMT)
committerJason Evans <jasone@canonware.com>2017-06-23 18:48:00 (GMT)
commitd49ac4c7096b79539ce84fa1bfe122bc9e3f1b43 (patch)
treec100e0318c4435247b09fb05efe41f60fde5cadf
parenta3f4977217af417b547e34cec3f5bd16874b8aa9 (diff)
downloadjemalloc-d49ac4c7096b79539ce84fa1bfe122bc9e3f1b43.zip
jemalloc-d49ac4c7096b79539ce84fa1bfe122bc9e3f1b43.tar.gz
jemalloc-d49ac4c7096b79539ce84fa1bfe122bc9e3f1b43.tar.bz2
Fix assertion typos.
Reported by Conrad Meyer.
-rw-r--r--src/ctl.c2
-rw-r--r--src/jemalloc.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/ctl.c b/src/ctl.c
index dfbeddd..a647c6c 100644
--- a/src/ctl.c
+++ b/src/ctl.c
@@ -1970,7 +1970,7 @@ arena_reset_finish_background_thread(tsd_t *tsd, unsigned arena_ind) {
unsigned ind = arena_ind % ncpus;
background_thread_info_t *info =
&background_thread_info[ind];
- assert(info->state = background_thread_paused);
+ assert(info->state == background_thread_paused);
malloc_mutex_lock(tsd_tsdn(tsd), &info->mtx);
info->state = background_thread_started;
malloc_mutex_unlock(tsd_tsdn(tsd), &info->mtx);
diff --git a/src/jemalloc.c b/src/jemalloc.c
index c773cc4..aa79633 100644
--- a/src/jemalloc.c
+++ b/src/jemalloc.c
@@ -1799,7 +1799,7 @@ imalloc_body(static_opts_t *sopts, dynamic_opts_t *dopts, tsd_t *tsd) {
*/
assert(dopts->tcache_ind == TCACHE_IND_AUTOMATIC ||
dopts->tcache_ind == TCACHE_IND_NONE);
- assert(dopts->arena_ind = ARENA_IND_AUTOMATIC);
+ assert(dopts->arena_ind == ARENA_IND_AUTOMATIC);
dopts->tcache_ind = TCACHE_IND_NONE;
/* We know that arena 0 has already been initialized. */
dopts->arena_ind = 0;