Page MenuHome

Initialize the fourth and final instance variable of MemoryProxy
ClosedPublic

Authored by Michael (michael64) on Dec 14 2021, 11:18 AM.

Details

Summary

The constructor of MemoryProxy initializes 3 of 4 instances variables.
If a MemoryProxy is constructed and MemoryProxy::free is called
on this instance, buffer_ is undefined and 'delete buffer_;' causes errors.

Although this misuse pattern does not exist in the current codebase
it already tripped up the Address Sanitizer on various occasions
while debugging unrelated problems.

Diff Detail