// // sub_7D0120 from 0x7d0120 to 0x7d0270 (336 bytes) // // 1 xrefs: // > @ 0xa3079c // // 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 // int __fastcall sub_7D0120(int a1, _BYTE *a2, int a3) { _DWORD *v3; // r4 int v6; // r8 int v7; // r7 int i; // r12 int v9; // r3 int v10; // r1 int v11; // r0 _BYTE *v12; // r2 _BYTE *v13; // r1 int v14; // r3 char v15; // t1 bool v16; // cc int v17; // r3 int v18; // r1 int v20; // r0 int v21; // r10 v3 = *(_DWORD **)(a1 + 32); v6 = a3 - 1; v7 = 0; BIO_clear_flags(a1, 15); for ( i = v3[3]; ; i = v20 ) { while ( i > 0 ) { v9 = v3[2]; v10 = v3[4]; if ( v6 > 0 ) { *a2 = *(_BYTE *)(v9 + v10); v11 = *(unsigned __int8 *)(v9 + v10); v12 = a2 + 1; v13 = (_BYTE *)(v9 + v10); if ( v11 == 10 ) { v17 = 1; } else { v14 = 0; do { i = v3[3]; v16 = v6 <= ++v14; if ( v6 > v14 ) v16 = i <= v14; if ( v16 ) { v10 = v3[4]; a2 = v12; goto LABEL_12; } v15 = *++v13; *v12++ = v15; } while ( *v13 != 10 ); v17 = v14 + 1; } v18 = v3[4] + v17; v7 += v17; v3[3] -= v17; v3[4] = v18; goto LABEL_16; } v14 = 0; LABEL_12: i -= v14; v6 -= v14; v3[3] = i; v3[4] = v14 + v10; v7 += v14; if ( !v6 ) { v12 = a2; LABEL_16: *v12 = 0; return v7; } } v20 = BIO_read(*(_DWORD *)(a1 + 36), v3[2], *v3); v21 = v20; if ( v20 <= 0 ) break; v3[3] = v20; v3[4] = 0; } BIO_copy_next_retry(a1); *a2 = 0; if ( !v21 ) return v7; if ( v7 <= 0 ) return v21; return v7; }
GD Web Decomp Icon

GD Web Decomp

Raw Source