5 Jul
2023
5 Jul
'23
12:24 p.m.
Hans Leidekker (@hans) commented about dlls/bcryptprimitives/bcryptprimitives_main.c:
+ +#include "windows.h" +#include "ntsecapi.h" + +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(bcrypt); + +BOOL WINAPI ProcessPrng(PBYTE pbData, SIZE_T cbData) +{ + if (RtlGenRandom(pbData, cbData)) return TRUE; + + /* ProcessPrng is documented as never failing. */ + FIXME("RtlGenRandom failed in ProcessPrng.\n"); + return FALSE; +} There's no need for the FIXME:
BOOL WINAPI ProcessPrng(BYTE *data, SIZE_T size)
{
return RtlGenRandom(data, size);
}
And then you don't need the wine/debug.h include and debug channel declaration. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/2228#note_37983