mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
klee: Fix possible assertion error
No idea how it did not happen to hit me yet.
This commit is contained in:
parent
4c8ed65b60
commit
c03dc13bb7
@ -35,6 +35,9 @@ void *xmalloc(const size_t size)
|
|||||||
|
|
||||||
void xfree(void *const p)
|
void xfree(void *const p)
|
||||||
{
|
{
|
||||||
|
if (p == NULL) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
RINGBUF_FORALL(&arecs, AllocRecord, arec) {
|
RINGBUF_FORALL(&arecs, AllocRecord, arec) {
|
||||||
if (arec->ptr == p) {
|
if (arec->ptr == p) {
|
||||||
allocated_memory -= arec->size;
|
allocated_memory -= arec->size;
|
||||||
|
Loading…
Reference in New Issue
Block a user