//
// memcpy_s from 0x18013f40c to 0x18013f493 (135 bytes)
//
// 7 xrefs:
// > __crt_strtox::divide @ 0x18013de06
// > __crt_strtox::divide @ 0x18013de31
// > __crt_strtox::divide @ 0x18013de9d
// > __acrt_fltout @ 0x18013f174
// > __acrt_fltout @ 0x18013f21f
// > __acrt_fltout @ 0x18013f2ef
// > ??> @ 0x180203b60
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
errno_t __cdecl memcpy_s(
void *const Destination,
const rsize_t DestinationSize,
const void *const Source,
const rsize_t SourceSize)
{
int *v8; // rax
errno_t v9; // ebx
if ( !SourceSize )
return 0;
if ( !Destination )
goto LABEL_4;
if ( Source && DestinationSize >= SourceSize )
{
memmove(Destination, Source, SourceSize);
return 0;
}
memset(Destination, 0, DestinationSize);
if ( !Source )
{
LABEL_4:
v8 = errno();
v9 = 22;
LABEL_5:
*v8 = v9;
invalid_parameter_noinfo();
return v9;
}
if ( DestinationSize < SourceSize )
{
v8 = errno();
v9 = 34;
goto LABEL_5;
}
return 22;
}