diff options
author | Maria Matejka <mq@ucw.cz> | 2020-05-01 15:34:17 +0200 |
---|---|---|
committer | Maria Matejka <mq@ucw.cz> | 2020-05-01 15:34:17 +0200 |
commit | 048eb2ddf1ee9587d9fa30cbb3f87d6f650a2133 (patch) | |
tree | fdec4c5679a02c901cf2bc92fd81618c6f12d48e /lib/slab.c | |
parent | 17de3a023f7bde293892b41bfafe5740c8553fc8 (diff) | |
parent | 59238768b3b05fa134348d2232b42537d0403994 (diff) |
Merge remote-tracking branch 'origin/mq-static-analysis'
Diffstat (limited to 'lib/slab.c')
-rw-r--r-- | lib/slab.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -216,8 +216,11 @@ sl_new_head(slab *s) struct sl_obj *no; uint n = s->objs_per_slab; - h->first_free = o; - h->num_full = 0; + *h = (struct sl_head) { + .first_free = o, + .num_full = 0, + }; + while (n--) { o->slab = h; |