Is there a Mac OS X equivalent of RtlSecureZeroMemory / SecureZeroMemory, a function which zeroes a block of memory, but the call will not be optimized away by the compiler?
Is there a Mac OS X equivalent of RtlSecureZeroMemory / SecureZeroMemory , a function
Share
Write your own function:
EDIT: to the question in the comments, why not
memset? Thememsetfunction call could be optimized away by the compiler if the array object is no futher accessed.Note that C11 adds the (optional) function
memset_sand the Standard guarantees the function call cannot be optimized away: