// // sub_978B68 from 0x978b68 to 0x978c04 (156 bytes) // // 0 xrefs: // // 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:06:00 +0000 // int __fastcall sub_978B68(unsigned __int8 *a1, char *a2, unsigned int a3) { unsigned int v4; // r1 signed int v5; // r5 signed int v6; // r6 unsigned __int8 *v7; // r8 size_t v8; // r0 unsigned __int8 *v9; // r12 char *v10; // r3 char *v11; // r9 unsigned __int8 *v12; // lr unsigned __int8 *v13; // r1 int v14; // r4 size_t v15; // r4 unsigned __int8 *v16; // r1 int v17; // r6 int v18; // t1 int v19; // r2 bool v20; // zf int v21; // r1 v4 = *a1; v5 = a3; if ( (v4 & 1) != 0 ) { v7 = *((unsigned __int8 **)a1 + 2); v6 = *((_DWORD *)a1 + 1); } else { v6 = v4 >> 1; v7 = a1 + 1; } if ( v6 < a3 ) v5 = v6; v8 = strlen(a2); if ( v6 - v5 > v8 ) v6 = v5 + v8; v9 = &v7[v6]; if ( v8 && v6 >= (int)v8 ) { v10 = &a2[v8]; v11 = a2 - 2; v12 = &v7[v6]; LABEL_11: v13 = v12 + 1; while ( &v7[v8] != v13 ) { v14 = *(v13 - 2); --v13; if ( v14 == (unsigned __int8)*(v10 - 1) ) { v12 = v13 - 1; v15 = v8; v16 = v13 - 1; while ( v15 != 1 ) { v17 = (unsigned __int8)v11[v15--]; v18 = *--v16; if ( v18 != v17 ) goto LABEL_11; } goto LABEL_19; } } } v16 = v9; LABEL_19: v19 = v16 - v7; v20 = v16 == v9; v21 = v16 - v7; if ( v20 ) v21 = -1; if ( !v8 ) return v19; return v21; }
GD Web Decomp Icon

GD Web Decomp

Raw Source