diff --git a/include/WinStd/Common.h b/include/WinStd/Common.h index cf14e15e..14d5437d 100644 --- a/include/WinStd/Common.h +++ b/include/WinStd/Common.h @@ -1951,11 +1951,11 @@ namespace winstd /// /// Deallocate object at _Ptr sanitizing its content first /// - void deallocate(_In_ pointer _Ptr, _In_ size_type _Size) + void deallocate(_In_ pointer _Ptr, _In_ size_type _Count) { // Sanitize then free. - SecureZeroMemory(_Ptr, _Size); - _Mybase::deallocate(_Ptr, _Size); + SecureZeroMemory(_Ptr, sizeof(_Ty) * _Count); + _Mybase::deallocate(_Ptr, _Count); } };