Fix customData free

This commit is contained in:
Mathieu Maret 2024-02-10 22:49:24 +01:00
parent 88b9c3160b
commit 3339f8b059

View File

@ -19,6 +19,9 @@ static int zeroClose(struct uAddrVirtualReg *vreg)
{ {
struct zeroMappedEntry *ent = (struct zeroMappedEntry *)vreg->res->customData; struct zeroMappedEntry *ent = (struct zeroMappedEntry *)vreg->res->customData;
ent->refCnt--; ent->refCnt--;
if (ent->refCnt == 0) {
free(vreg->res->customData);
}
return 0; return 0;
} }