//
// sub_1403784F0 from 0x1403784f0 to 0x140378587 (151 bytes)
//
// 10 xrefs:
// > sub_1403741E0 @ 0x1403743b6
// > sub_140375320 @ 0x1403754fa
// > sub_14054ED70 @ 0x14054eec7
// > sub_14054F310 @ 0x14054f467
// > sub_14054F4F0 @ 0x14054f652
// > ?dtor$0@?0???$__acrt_get_current_directory@U__crt_win32_buffer_internal_dynamic_resizing@@@@YAHAEAV?$__crt_win32_buffer@DU__crt_win32_buffer_internal_dynamic_resizing@@@@@Z@4HA_102 @ 0x1406abfd7
// > ??> @ 0x1408bbe67
// > ??> @ 0x1408bc85c
// > ??> @ 0x1408bc86c
// > ??> @ 0x140922508
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:31:02 +0000
//
void __fastcall sub_1403784F0(_QWORD *a1)
{
__int64 v2; // rbx
__int64 i; // rdi
_QWORD *v4; // rcx
if ( a1[1] )
{
v2 = a1[3];
for ( i = a1[4]; v2 != i; v2 += 56 )
sub_140069730(v2 + 32);
v4 = (_QWORD *)a1[1];
if ( (unsigned __int64)(56LL * a1[2]) >= 0x1000 )
{
if ( (unsigned __int64)v4 - *(v4 - 1) - 8 > 0x1F )
invoke_watson(nullptr, nullptr, nullptr, 0, 0);
v4 = (_QWORD *)*(v4 - 1);
}
j_j_free(v4);
}
}