// // sub_971430 from 0x971430 to 0x9715ae (382 bytes) // // 3 xrefs: // > std::__ndk1::codecvt::do_in @ 0x971400 // > std::__ndk1::__codecvt_utf8::do_in @ 0x9717e6 // > std::__ndk1::__codecvt_utf8::do_in @ 0x971b82 // // This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False! // // 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 12:05:53 +0000 // int __fastcall sub_971430( unsigned __int8 *a1, unsigned int a2, unsigned __int8 **a3, unsigned int *a4, unsigned int a5, unsigned int **a6, unsigned int a7, char a8) { unsigned __int8 *v8; // r3 int v9; // r0 bool v10; // zf unsigned int *v11; // r7 int v12; // r0 int v13; // r5 unsigned __int8 *v14; // r0 unsigned __int8 v15; // r0 unsigned int v16; // r0 unsigned __int8 v17; // r0 unsigned __int8 v18; // r4 unsigned __int8 v19; // r6 int v20; // r0 unsigned __int8 v21; // r9 int v22; // r6 unsigned int v23; // r0 int v24; // r4 bool v25; // zf unsigned int v26; // r0 *a3 = a1; *a6 = a4; v8 = *a3; if ( (a8 & 4) != 0 && (int)(a2 - (_DWORD)v8) >= 3 ) { v9 = *v8; v10 = v9 == 239; if ( v9 == 239 ) v10 = v8[1] == 187; if ( v10 && v8[2] == 191 ) { v8 += 3; *a3 = v8; } } if ( (unsigned int)v8 < a2 ) { v11 = *a6; while ( 1 ) { if ( (unsigned int)v11 >= a5 ) return (unsigned int)v8 < a2; v12 = (char)*v8; v13 = (unsigned __int8)v12; if ( v12 >= 0 ) { if ( (unsigned __int8)v12 > a7 ) return 2; *v11 = (unsigned __int8)v12; v14 = v8 + 1; goto LABEL_48; } if ( (unsigned __int8)v12 < 0xC2u ) return 2; if ( (unsigned __int8)v12 > 0xDFu ) break; if ( (int)(a2 - (_DWORD)v8) < 2 ) return 1; v15 = v8[1]; if ( (v15 & 0xC0) != 0x80 ) return 2; v16 = v15 & 0x3F | (v13 << 6) & 0x7C0; if ( v16 > a7 ) return 2; *v11 = v16; v14 = v8 + 2; LABEL_48: *a3 = v14; v11 = *a6 + 1; *a6 = v11; v8 = *a3; if ( (unsigned int)*a3 >= a2 ) return (unsigned int)v8 < a2; } if ( (unsigned __int8)v12 <= 0xEFu ) { if ( (int)(a2 - (_DWORD)v8) < 3 ) return 1; v17 = v8[1]; v18 = v8[2]; if ( v13 == 237 ) { v22 = v17 & 0xE0; } else { if ( v13 == 224 ) { if ( (v17 & 0xE0) != 0xA0 ) return 2; LABEL_36: if ( (v18 & 0xC0) != 0x80 ) return 2; v23 = v18 & 0x3F | (unsigned __int16)((_WORD)v13 << 12) | ((v17 & 0x3F) << 6); if ( v23 > a7 ) return 2; *v11 = v23; v14 = v8 + 3; goto LABEL_48; } v22 = v17 & 0xC0; } if ( v22 != 128 ) return 2; goto LABEL_36; } if ( (unsigned __int8)v12 > 0xF4u ) return 2; if ( (int)(a2 - (_DWORD)v8) < 4 ) return 1; v19 = v8[1]; v20 = v8[2]; v21 = v8[3]; if ( v13 == 244 ) { v24 = v19 & 0xF0; } else { if ( v13 == 240 ) { if ( (unsigned __int8)(v19 + 112) >= 0x30u ) return 2; LABEL_42: v25 = (v20 & 0xC0) == 128; if ( (v20 & 0xC0) == 0x80 ) v25 = (v21 & 0xC0) == 128; if ( !v25 ) return 2; v26 = (v20 << 6) & 0xFC0 | (v13 << 18) & 0x1C0000 | ((v19 & 0x3F) << 12) | v21 & 0x3F; if ( v26 > a7 ) return 2; *v11 = v26; v14 = v8 + 4; goto LABEL_48; } v24 = v19 & 0xC0; } if ( v24 != 128 ) return 2; goto LABEL_42; } return (unsigned int)v8 < a2; }
GD Web Decomp Icon

GD Web Decomp

Raw Source