kernel: umem: fix use of uninitialized fptr in freelist_pop
CID 156230 (#1 of 1): Uninitialized pointer read (UNINIT)9. uninit_use: Using uninitialized value fptr.
This commit is contained in:
parent
1cb4610ed2
commit
237b7709ae
@ -305,6 +305,9 @@ freelist_pop(int blankslot, int originally_allocated)
|
||||
}
|
||||
}
|
||||
|
||||
if(fimg == nil)
|
||||
panic("no free image in sleeping free list");
|
||||
|
||||
mkqid(&fimg->qid, ~0, ~0, QTDIR); /* so that it cannot be found by hash */
|
||||
ptr = *fptr;
|
||||
*fptr = fimg->fnext;
|
||||
|
Loading…
x
Reference in New Issue
Block a user