
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

control * ctrl_radiobuttons(controlset *s,char *label,char shortcut,int ncolumns,intorptr helpctx,
                           handler_fn handler,intorptr context,...)

{
  int *piVar1;
  control *pcVar2;
  size_t n;
  char **ppcVar3;
  intorptr *piVar4;
  char *pcVar5;
  undefined1 *puVar6;
  control **ppcVar7;
  size_t sVar8;
  undefined4 *puVar9;
  int iVar10;
  int in_stack_00000020;
  
  pcVar2 = (control *)safemalloc(1,0x3c);
  iVar10 = s->ncontrols;
  if (iVar10 < s->ctrlsize) {
    ppcVar7 = s->ctrls;
  }
  else {
    s->ctrlsize = iVar10 + 0x20U;
    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);
    iVar10 = s->ncontrols;
    s->ctrls = ppcVar7;
  }
  s->ncontrols = iVar10 + 1;
  ppcVar7[iVar10] = pcVar2;
  iVar10 = s->ncolumns;
  (pcVar2->generic).type = 2;
  (pcVar2->generic).tabdelay = 0;
  (pcVar2->generic).label = (char *)0x0;
  (pcVar2->generic).column = (iVar10 + -1) * 0x10000;
  (pcVar2->generic).helpctx = helpctx;
  (pcVar2->generic).handler = handler;
  (pcVar2->generic).context = context;
  if (label != (char *)0x0) {
    label = dupstr(label);
  }
  (pcVar2->generic).label = label;
  (pcVar2->editbox).shortcut = shortcut;
  (pcVar2->editbox).percentwidth = ncolumns;
  puVar6 = &stack0x00000024;
  if (in_stack_00000020 == 0) {
    n = 0;
  }
  else {
    sVar8 = 0;
    if (shortcut == '\0') {
      do {
        n = sVar8 + 1;
        if (*(int *)(puVar6 + 8) == 0) break;
        piVar1 = (int *)(puVar6 + 0x14);
        sVar8 = sVar8 + 2;
        puVar6 = puVar6 + 0x18;
        n = sVar8;
      } while (*piVar1 != 0);
    }
    else {
      do {
        piVar1 = (int *)(puVar6 + 4);
        sVar8 = sVar8 + 1;
        puVar6 = puVar6 + 8;
        n = sVar8;
      } while (*piVar1 != 0);
    }
  }
  (pcVar2->editbox).password = n;
  if (shortcut == '\0') {
    pcVar5 = (char *)safemalloc(n,1);
    (pcVar2->radio).shortcuts = pcVar5;
    n = (pcVar2->editbox).password;
  }
  else {
    (pcVar2->radio).shortcuts = (char *)0x0;
  }
  iVar10 = 0;
  ppcVar3 = (char **)safemalloc(n,4);
  (pcVar2->radio).buttons = ppcVar3;
  piVar4 = (intorptr *)safemalloc((pcVar2->editbox).password,4);
  (pcVar2->radio).buttondata = piVar4;
  puVar9 = &stack0x00000020;
  if (0 < (pcVar2->editbox).password) {
    do {
      while( true ) {
        ppcVar3 = (pcVar2->radio).buttons;
        pcVar5 = dupstr((char *)*puVar9);
        ppcVar3[iVar10] = pcVar5;
        if ((pcVar2->editbox).shortcut == '\0') break;
        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);
        iVar10 = iVar10 + 1;
        puVar9 = puVar9 + 2;
        if ((pcVar2->editbox).password <= iVar10) {
          return pcVar2;
        }
      }
      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];
      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);
      iVar10 = iVar10 + 1;
      puVar9 = puVar9 + 3;
    } while (iVar10 < (pcVar2->editbox).password);
  }
  return pcVar2;
}



/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

undefined4 *
FUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,
            undefined4 param_6,undefined4 param_7,int param_8)

{
  int *piVar1;
  undefined4 *puVar2;
  int iVar3;
  undefined4 uVar4;
  undefined1 *puVar5;
  int iVar6;
  undefined4 *puVar7;
  
  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);
  iVar3 = *(int *)(param_1 + 0x10);
  if (iVar3 < *(int *)(param_1 + 0x14)) {
    iVar6 = *(int *)(param_1 + 0x18);
  }
  else {
    *(int *)(param_1 + 0x14) = iVar3 + 0x20;
    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);
    iVar3 = *(int *)(param_1 + 0x10);
    *(int *)(param_1 + 0x18) = iVar6;
  }
  *(int *)(param_1 + 0x10) = iVar3 + 1;
  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;
  iVar3 = *(int *)(param_1 + 0xc);
  *puVar2 = 2;
  puVar2[2] = 0;
  puVar2[1] = 0;
  puVar2[3] = (iVar3 + -1) * 0x10000;
  puVar2[6] = param_5;
  puVar2[4] = param_6;
  puVar2[5] = param_7;
  if (param_2 != 0) {
    param_2 = FUN_00030420(param_2);
  }
  puVar2[1] = param_2;
  *(char *)(puVar2 + 7) = param_3;
  puVar2[8] = param_4;
  puVar5 = &stack0x00000024;
  if (param_8 == 0) {
    iVar3 = 0;
  }
  else {
    iVar6 = 0;
    if (param_3 == '\0') {
      do {
        iVar3 = iVar6 + 1;
        if (*(int *)(puVar5 + 8) == 0) break;
        piVar1 = (int *)(puVar5 + 0x14);
        iVar6 = iVar6 + 2;
        puVar5 = puVar5 + 0x18;
        iVar3 = iVar6;
      } while (*piVar1 != 0);
    }
    else {
      do {
        piVar1 = (int *)(puVar5 + 4);
        iVar6 = iVar6 + 1;
        puVar5 = puVar5 + 8;
        iVar3 = iVar6;
      } while (*piVar1 != 0);
    }
  }
  puVar2[9] = iVar3;
  if (param_3 == '\0') {
    uVar4 = FUN_000313e0(iVar3,1);
    puVar2[0xb] = uVar4;
    iVar3 = puVar2[9];
  }
  else {
    puVar2[0xb] = 0;
  }
  iVar6 = 0;
  uVar4 = FUN_000313e0(iVar3,4);
  puVar2[10] = uVar4;
  uVar4 = FUN_000313e0(puVar2[9],4);
  puVar2[0xc] = uVar4;
  puVar7 = &param_8;
  if (0 < (int)puVar2[9]) {
    do {
      while( true ) {
        iVar3 = puVar2[10];
        uVar4 = FUN_00030420(*puVar7);
        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;
        if (*(char *)(puVar2 + 7) == '\0') break;
        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];
        iVar6 = iVar6 + 1;
        puVar7 = puVar7 + 2;
        if ((int)puVar2[9] <= iVar6) {
          return puVar2;
        }
      }
      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];
      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];
      iVar6 = iVar6 + 1;
      puVar7 = puVar7 + 3;
    } while (iVar6 < (int)puVar2[9]);
  }
  return puVar2;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x0001b410
ADD EBX,0x9b75b
SUB ESP,0x24
MOV EBP,dword ptr [ESP + 0x38]
MOV EDI,dword ptr [ESP + 0x40]
PUSH 0x3c
PUSH 0x1
CALL 0x000313e0
MOV ECX,dword ptr [EBP + 0x10]
ADD ESP,0x10
MOV ESI,EAX
CMP ECX,dword ptr [EBP + 0x14]
JGE 0x0002a200
MOV EAX,dword ptr [EBP + 0x18]
LEA EDX,[ECX + 0x1]
MOV dword ptr [EBP + 0x10],EDX
MOV dword ptr [EAX + ECX*0x4],ESI
MOV EAX,dword ptr [EBP + 0xc]
MOV ECX,dword ptr [ESP + 0x34]
MOV dword ptr [ESI],0x2
SUB EAX,0x1
MOV dword ptr [ESI + 0x8],0x0
SHL EAX,0x10
MOV dword ptr [ESI + 0x4],0x0
MOV dword ptr [ESI + 0xc],EAX
MOV EAX,dword ptr [ESP + 0x40]
MOV dword ptr [ESI + 0x18],EAX
MOV EAX,dword ptr [ESP + 0x44]
MOV dword ptr [ESI + 0x10],EAX
MOV EAX,dword ptr [ESP + 0x48]
MOV dword ptr [ESI + 0x14],EAX
TEST ECX,ECX
JZ 0x0002a0d0
SUB ESP,0xc
PUSH dword ptr [ESP + 0x40]
CALL 0x00030420
MOV dword ptr [ESP + 0x44],EAX
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0x34]
MOV ECX,EDI
MOV dword ptr [ESI + 0x4],EAX
MOV EAX,EDI
MOV byte ptr [ESI + 0x1c],AL
MOV EAX,dword ptr [ESP + 0x3c]
MOV dword ptr [ESI + 0x20],EAX
MOV EDX,dword ptr [ESP + 0x4c]
LEA EAX,[ESP + 0x50]
TEST EDX,EDX
JZ 0x0002a248
TEST CL,CL
MOV EDX,0x0
JZ 0x0002a1b0
LEA ESI,[ESI]
ADD EAX,0x8
MOV EBP,dword ptr [EAX + -0x4]
ADD EDX,0x1
TEST EBP,EBP
JNZ 0x0002a108
MOV EAX,EDX
MOV dword ptr [ESI + 0x24],EDX
TEST CL,CL
JZ 0x0002a228
MOV dword ptr [ESI + 0x2c],0x0
SUB ESP,0x8
XOR EDI,EDI
PUSH 0x4
PUSH EAX
CALL 0x000313e0
MOV dword ptr [ESI + 0x28],EAX
POP EAX
POP EDX
PUSH 0x4
PUSH dword ptr [ESI + 0x24]
CALL 0x000313e0
MOV ECX,dword ptr [ESI + 0x24]
LEA EBP,[ESP + 0x5c]
ADD ESP,0x10
MOV dword ptr [ESI + 0x30],EAX
TEST ECX,ECX
JLE 0x0002a1f0
LEA ESI,[ESI]
MOV EAX,dword ptr [ESI + 0x28]
SUB ESP,0xc
LEA EDX,[EAX + EDI*0x4]
MOV dword ptr [ESP + 0x18],EDX
PUSH dword ptr [EBP]
CALL 0x00030420
MOV EDX,dword ptr [ESP + 0x1c]
ADD ESP,0x10
MOV dword ptr [EDX],EAX
CMP byte ptr [ESI + 0x1c],0x0
LEA EAX,[EBP + 0x8]
JNZ 0x0002a1d8
MOV EDX,dword ptr [ESI + 0x2c]
MOV EAX,dword ptr [EBP + 0x4]
LEA ECX,[EBP + 0xc]
MOV byte ptr [EDX + EDI*0x1],AL
MOV EAX,dword ptr [ESI + 0x30]
MOV EDX,dword ptr [EBP + 0x8]
MOV dword ptr [EAX + EDI*0x4],EDX
ADD EDI,0x1
CMP dword ptr [ESI + 0x24],EDI
JLE 0x0002a1f0
MOV EBP,ECX
JMP 0x0002a160
ADD EAX,0xc
MOV EDI,dword ptr [EAX + -0x4]
ADD EDX,0x1
TEST EDI,EDI
JZ 0x0002a115
ADD EAX,0xc
MOV EDI,dword ptr [EAX + -0x4]
ADD EDX,0x1
TEST EDI,EDI
JNZ 0x0002a1b0
JMP 0x0002a115
MOV EDX,dword ptr [ESI + 0x30]
MOV ECX,dword ptr [EBP + 0x4]
MOV dword ptr [EDX + EDI*0x4],ECX
ADD EDI,0x1
CMP dword ptr [ESI + 0x24],EDI
JLE 0x0002a1f0
MOV EBP,EAX
JMP 0x0002a160
ADD ESP,0x1c
MOV EAX,ESI
POP EBX
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0x4
ADD ECX,0x20
MOV dword ptr [EBP + 0x14],ECX
PUSH 0x4
PUSH ECX
PUSH dword ptr [EBP + 0x18]
CALL 0x000314a0
MOV ECX,dword ptr [EBP + 0x10]
ADD ESP,0x10
MOV dword ptr [EBP + 0x18],EAX
JMP 0x0002a077
SUB ESP,0x8
PUSH 0x1
PUSH EAX
CALL 0x000313e0
ADD ESP,0x10
MOV dword ptr [ESI + 0x2c],EAX
MOV EAX,dword ptr [ESI + 0x24]
JMP 0x0002a129
XOR EAX,EAX
XOR EDX,EDX
JMP 0x0002a117
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 *\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)\n\n{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}\n\n" comment (function_definition "undefined4 *\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)\n\n{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}" type_identifier (pointer_declarator "*\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" * (function_declarator "FUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" identifier (parameter_list "(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "char param_3" primitive_type identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) , (parameter_declaration "undefined4 param_5" type_identifier identifier) , (parameter_declaration "undefined4 param_6" type_identifier identifier) , (parameter_declaration "undefined4 param_7" type_identifier identifier) , (parameter_declaration "int param_8" primitive_type identifier) )))) (compound_statement "{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "undefined4 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (declaration "undefined1 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "undefined4 *puVar7;" type_identifier (pointer_declarator "*puVar7" * identifier) ;) (expression_statement "puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);" (assignment_expression "puVar2 = (undefined4 *)FUN_000313e0(1,0x3c)" identifier = (cast_expression "(undefined4 *)FUN_000313e0(1,0x3c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_000313e0(1,0x3c)" identifier (argument_list "(1,0x3c)" ( number_literal , number_literal ))))) ;) (expression_statement "iVar3 = *(int *)(param_1 + 0x10);" (assignment_expression "iVar3 = *(int *)(param_1 + 0x10)" identifier = (pointer_expression "*(int *)(param_1 + 0x10)" * (cast_expression "(int *)(param_1 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) (if_statement "if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" if (parenthesized_expression "(iVar3 < *(int *)(param_1 + 0x14))" ( (binary_expression "iVar3 < *(int *)(param_1 + 0x14)" identifier < (pointer_expression "*(int *)(param_1 + 0x14)" * (cast_expression "(int *)(param_1 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    iVar6 = *(int *)(param_1 + 0x18);\n  }" { (expression_statement "iVar6 = *(int *)(param_1 + 0x18);" (assignment_expression "iVar6 = *(int *)(param_1 + 0x18)" identifier = (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) ))))) ;) }) (else_clause "else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" else (compound_statement "{\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" { (expression_statement "*(int *)(param_1 + 0x14) = iVar3 + 0x20;" (assignment_expression "*(int *)(param_1 + 0x14) = iVar3 + 0x20" (pointer_expression "*(int *)(param_1 + 0x14)" * (cast_expression "(int *)(param_1 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) )))) = (binary_expression "iVar3 + 0x20" identifier + number_literal)) ;) (expression_statement "iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);" (assignment_expression "iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" identifier = (call_expression "FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" identifier (argument_list "(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" ( (pointer_expression "*(undefined4 *)(param_1 + 0x18)" * (cast_expression "(undefined4 *)(param_1 + 0x18)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) , (binary_expression "iVar3 + 0x20" identifier + number_literal) , number_literal )))) ;) (expression_statement "iVar3 = *(int *)(param_1 + 0x10);" (assignment_expression "iVar3 = *(int *)(param_1 + 0x10)" identifier = (pointer_expression "*(int *)(param_1 + 0x10)" * (cast_expression "(int *)(param_1 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) (expression_statement "*(int *)(param_1 + 0x18) = iVar6;" (assignment_expression "*(int *)(param_1 + 0x18) = iVar6" (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) = identifier) ;) }))) (expression_statement "*(int *)(param_1 + 0x10) = iVar3 + 1;" (assignment_expression "*(int *)(param_1 + 0x10) = iVar3 + 1" (pointer_expression "*(int *)(param_1 + 0x10)" * (cast_expression "(int *)(param_1 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (expression_statement "*(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;" (assignment_expression "*(undefined4 **)(iVar6 + iVar3 * 4) = puVar2" (pointer_expression "*(undefined4 **)(iVar6 + iVar3 * 4)" * (cast_expression "(undefined4 **)(iVar6 + iVar3 * 4)" ( (type_descriptor "undefined4 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(iVar6 + iVar3 * 4)" ( (binary_expression "iVar6 + iVar3 * 4" identifier + (binary_expression "iVar3 * 4" identifier * number_literal)) )))) = identifier) ;) (expression_statement "iVar3 = *(int *)(param_1 + 0xc);" (assignment_expression "iVar3 = *(int *)(param_1 + 0xc)" identifier = (pointer_expression "*(int *)(param_1 + 0xc)" * (cast_expression "(int *)(param_1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) ))))) ;) (expression_statement "*puVar2 = 2;" (assignment_expression "*puVar2 = 2" (pointer_expression "*puVar2" * identifier) = number_literal) ;) (expression_statement "puVar2[2] = 0;" (assignment_expression "puVar2[2] = 0" (subscript_expression "puVar2[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "puVar2[1] = 0;" (assignment_expression "puVar2[1] = 0" (subscript_expression "puVar2[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "puVar2[3] = (iVar3 + -1) * 0x10000;" (assignment_expression "puVar2[3] = (iVar3 + -1) * 0x10000" (subscript_expression "puVar2[3]" identifier [ number_literal ]) = (binary_expression "(iVar3 + -1) * 0x10000" (parenthesized_expression "(iVar3 + -1)" ( (binary_expression "iVar3 + -1" identifier + number_literal) )) * number_literal)) ;) (expression_statement "puVar2[6] = param_5;" (assignment_expression "puVar2[6] = param_5" (subscript_expression "puVar2[6]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar2[4] = param_6;" (assignment_expression "puVar2[4] = param_6" (subscript_expression "puVar2[4]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar2[5] = param_7;" (assignment_expression "puVar2[5] = param_7" (subscript_expression "puVar2[5]" identifier [ number_literal ]) = identifier) ;) (if_statement "if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }" if (parenthesized_expression "(param_2 != 0)" ( (binary_expression "param_2 != 0" identifier != number_literal) )) (compound_statement "{\n    param_2 = FUN_00030420(param_2);\n  }" { (expression_statement "param_2 = FUN_00030420(param_2);" (assignment_expression "param_2 = FUN_00030420(param_2)" identifier = (call_expression "FUN_00030420(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) })) (expression_statement "puVar2[1] = param_2;" (assignment_expression "puVar2[1] = param_2" (subscript_expression "puVar2[1]" identifier [ number_literal ]) = identifier) ;) (expression_statement "*(char *)(puVar2 + 7) = param_3;" (assignment_expression "*(char *)(puVar2 + 7) = param_3" (pointer_expression "*(char *)(puVar2 + 7)" * (cast_expression "(char *)(puVar2 + 7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2 + 7)" ( (binary_expression "puVar2 + 7" identifier + number_literal) )))) = identifier) ;) (expression_statement "puVar2[8] = param_4;" (assignment_expression "puVar2[8] = param_4" (subscript_expression "puVar2[8]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar5 = &stack0x00000024;" (assignment_expression "puVar5 = &stack0x00000024" identifier = (pointer_expression "&stack0x00000024" & identifier)) ;) (if_statement "if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" if (parenthesized_expression "(param_8 == 0)" ( (binary_expression "param_8 == 0" identifier == number_literal) )) (compound_statement "{\n    iVar3 = 0;\n  }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" else (compound_statement "{\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (if_statement "if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" if (parenthesized_expression "(param_3 == '\0')" ( (binary_expression "param_3 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" { (do_statement "do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);" do (compound_statement "{\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      }" { (expression_statement "iVar3 = iVar6 + 1;" (assignment_expression "iVar3 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (if_statement "if (*(int *)(puVar5 + 8) == 0) break;" if (parenthesized_expression "(*(int *)(puVar5 + 8) == 0)" ( (binary_expression "*(int *)(puVar5 + 8) == 0" (pointer_expression "*(int *)(puVar5 + 8)" * (cast_expression "(int *)(puVar5 + 8)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar5 + 8)" ( (binary_expression "puVar5 + 8" identifier + number_literal) )))) == number_literal) )) (break_statement "break;" break ;)) (expression_statement "piVar1 = (int *)(puVar5 + 0x14);" (assignment_expression "piVar1 = (int *)(puVar5 + 0x14)" identifier = (cast_expression "(int *)(puVar5 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar5 + 0x14)" ( (binary_expression "puVar5 + 0x14" identifier + number_literal) )))) ;) (expression_statement "iVar6 = iVar6 + 2;" (assignment_expression "iVar6 = iVar6 + 2" identifier = (binary_expression "iVar6 + 2" identifier + number_literal)) ;) (expression_statement "puVar5 = puVar5 + 0x18;" (assignment_expression "puVar5 = puVar5 + 0x18" identifier = (binary_expression "puVar5 + 0x18" identifier + number_literal)) ;) (expression_statement "iVar3 = iVar6;" (assignment_expression "iVar3 = iVar6" identifier = identifier) ;) }) while (parenthesized_expression "(*piVar1 != 0)" ( (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" * identifier) != number_literal) )) ;) }) (else_clause "else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" else (compound_statement "{\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" { (do_statement "do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);" do (compound_statement "{\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      }" { (expression_statement "piVar1 = (int *)(puVar5 + 4);" (assignment_expression "piVar1 = (int *)(puVar5 + 4)" identifier = (cast_expression "(int *)(puVar5 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar5 + 4)" ( (binary_expression "puVar5 + 4" identifier + number_literal) )))) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "puVar5 = puVar5 + 8;" (assignment_expression "puVar5 = puVar5 + 8" identifier = (binary_expression "puVar5 + 8" identifier + number_literal)) ;) (expression_statement "iVar3 = iVar6;" (assignment_expression "iVar3 = iVar6" identifier = identifier) ;) }) while (parenthesized_expression "(*piVar1 != 0)" ( (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" * identifier) != number_literal) )) ;) }))) }))) (expression_statement "puVar2[9] = iVar3;" (assignment_expression "puVar2[9] = iVar3" (subscript_expression "puVar2[9]" identifier [ number_literal ]) = identifier) ;) (if_statement "if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }" if (parenthesized_expression "(param_3 == '\0')" ( (binary_expression "param_3 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }" { (expression_statement "uVar4 = FUN_000313e0(iVar3,1);" (assignment_expression "uVar4 = FUN_000313e0(iVar3,1)" identifier = (call_expression "FUN_000313e0(iVar3,1)" identifier (argument_list "(iVar3,1)" ( identifier , number_literal )))) ;) (expression_statement "puVar2[0xb] = uVar4;" (assignment_expression "puVar2[0xb] = uVar4" (subscript_expression "puVar2[0xb]" identifier [ number_literal ]) = identifier) ;) (expression_statement "iVar3 = puVar2[9];" (assignment_expression "iVar3 = puVar2[9]" identifier = (subscript_expression "puVar2[9]" identifier [ number_literal ])) ;) }) (else_clause "else {\n    puVar2[0xb] = 0;\n  }" else (compound_statement "{\n    puVar2[0xb] = 0;\n  }" { (expression_statement "puVar2[0xb] = 0;" (assignment_expression "puVar2[0xb] = 0" (subscript_expression "puVar2[0xb]" identifier [ number_literal ]) = number_literal) ;) }))) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "uVar4 = FUN_000313e0(iVar3,4);" (assignment_expression "uVar4 = FUN_000313e0(iVar3,4)" identifier = (call_expression "FUN_000313e0(iVar3,4)" identifier (argument_list "(iVar3,4)" ( identifier , number_literal )))) ;) (expression_statement "puVar2[10] = uVar4;" (assignment_expression "puVar2[10] = uVar4" (subscript_expression "puVar2[10]" identifier [ number_literal ]) = identifier) ;) (expression_statement "uVar4 = FUN_000313e0(puVar2[9],4);" (assignment_expression "uVar4 = FUN_000313e0(puVar2[9],4)" identifier = (call_expression "FUN_000313e0(puVar2[9],4)" identifier (argument_list "(puVar2[9],4)" ( (subscript_expression "puVar2[9]" identifier [ number_literal ]) , number_literal )))) ;) (expression_statement "puVar2[0xc] = uVar4;" (assignment_expression "puVar2[0xc] = uVar4" (subscript_expression "puVar2[0xc]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar7 = &param_8;" (assignment_expression "puVar7 = &param_8" identifier = (pointer_expression "&param_8" & identifier)) ;) (if_statement "if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }" if (parenthesized_expression "(0 < (int)puVar2[9])" ( (binary_expression "0 < (int)puVar2[9]" number_literal < (cast_expression "(int)puVar2[9]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "puVar2[9]" identifier [ number_literal ]))) )) (compound_statement "{\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }" { (do_statement "do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);" do (compound_statement "{\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    }" { (while_statement "while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }" { (expression_statement "iVar3 = puVar2[10];" (assignment_expression "iVar3 = puVar2[10]" identifier = (subscript_expression "puVar2[10]" identifier [ number_literal ])) ;) (expression_statement "uVar4 = FUN_00030420(*puVar7);" (assignment_expression "uVar4 = FUN_00030420(*puVar7)" identifier = (call_expression "FUN_00030420(*puVar7)" identifier (argument_list "(*puVar7)" ( (pointer_expression "*puVar7" * identifier) )))) ;) (expression_statement "*(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;" (assignment_expression "*(undefined4 *)(iVar3 + iVar6 * 4) = uVar4" (pointer_expression "*(undefined4 *)(iVar3 + iVar6 * 4)" * (cast_expression "(undefined4 *)(iVar3 + iVar6 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar6 * 4)" ( (binary_expression "iVar3 + iVar6 * 4" identifier + (binary_expression "iVar6 * 4" identifier * number_literal)) )))) = identifier) ;) (if_statement "if (*(char *)(puVar2 + 7) == '\0') break;" if (parenthesized_expression "(*(char *)(puVar2 + 7) == '\0')" ( (binary_expression "*(char *)(puVar2 + 7) == '\0'" (pointer_expression "*(char *)(puVar2 + 7)" * (cast_expression "(char *)(puVar2 + 7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2 + 7)" ( (binary_expression "puVar2 + 7" identifier + number_literal) )))) == (char_literal "'\0'" ' escape_sequence ')) )) (break_statement "break;" break ;)) (expression_statement "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];" (assignment_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1]" (pointer_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4)" * (cast_expression "(undefined4 *)(puVar2[0xc] + iVar6 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2[0xc] + iVar6 * 4)" ( (binary_expression "puVar2[0xc] + iVar6 * 4" (subscript_expression "puVar2[0xc]" identifier [ number_literal ]) + (binary_expression "iVar6 * 4" identifier * number_literal)) )))) = (subscript_expression "puVar7[1]" identifier [ number_literal ])) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "puVar7 = puVar7 + 2;" (assignment_expression "puVar7 = puVar7 + 2" identifier = (binary_expression "puVar7 + 2" identifier + number_literal)) ;) (if_statement "if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }" if (parenthesized_expression "((int)puVar2[9] <= iVar6)" ( (binary_expression "(int)puVar2[9] <= iVar6" (cast_expression "(int)puVar2[9]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "puVar2[9]" identifier [ number_literal ])) <= identifier) )) (compound_statement "{\n          return puVar2;\n        }" { (return_statement "return puVar2;" return identifier ;) })) })) (expression_statement "*(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];" (assignment_expression "*(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1]" (pointer_expression "*(char *)(puVar2[0xb] + iVar6)" * (cast_expression "(char *)(puVar2[0xb] + iVar6)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2[0xb] + iVar6)" ( (binary_expression "puVar2[0xb] + iVar6" (subscript_expression "puVar2[0xb]" identifier [ number_literal ]) + identifier) )))) = (cast_expression "(char)puVar7[1]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "puVar7[1]" identifier [ number_literal ]))) ;) (expression_statement "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];" (assignment_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2]" (pointer_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4)" * (cast_expression "(undefined4 *)(puVar2[0xc] + iVar6 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2[0xc] + iVar6 * 4)" ( (binary_expression "puVar2[0xc] + iVar6 * 4" (subscript_expression "puVar2[0xc]" identifier [ number_literal ]) + (binary_expression "iVar6 * 4" identifier * number_literal)) )))) = (subscript_expression "puVar7[2]" identifier [ number_literal ])) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "puVar7 = puVar7 + 3;" (assignment_expression "puVar7 = puVar7 + 3" identifier = (binary_expression "puVar7 + 3" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar6 < (int)puVar2[9])" ( (binary_expression "iVar6 < (int)puVar2[9]" identifier < (cast_expression "(int)puVar2[9]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "puVar2[9]" identifier [ number_literal ]))) )) ;) })) (return_statement "return puVar2;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\ncontrol * ctrl_radiobuttons(controlset *s,char *label,char shortcut,int ncolumns,intorptr helpctx,\n                           handler_fn handler,intorptr context,...)\n\n{\n  int *piVar1;\n  control *pcVar2;\n  size_t n;\n  char **ppcVar3;\n  intorptr *piVar4;\n  char *pcVar5;\n  undefined1 *puVar6;\n  control **ppcVar7;\n  size_t sVar8;\n  undefined4 *puVar9;\n  int iVar10;\n  int in_stack_00000020;\n  \n  pcVar2 = (control *)safemalloc(1,0x3c);\n  iVar10 = s->ncontrols;\n  if (iVar10 < s->ctrlsize) {\n    ppcVar7 = s->ctrls;\n  }\n  else {\n    s->ctrlsize = iVar10 + 0x20U;\n    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);\n    iVar10 = s->ncontrols;\n    s->ctrls = ppcVar7;\n  }\n  s->ncontrols = iVar10 + 1;\n  ppcVar7[iVar10] = pcVar2;\n  iVar10 = s->ncolumns;\n  (pcVar2->generic).type = 2;\n  (pcVar2->generic).tabdelay = 0;\n  (pcVar2->generic).label = (char *)0x0;\n  (pcVar2->generic).column = (iVar10 + -1) * 0x10000;\n  (pcVar2->generic).helpctx = helpctx;\n  (pcVar2->generic).handler = handler;\n  (pcVar2->generic).context = context;\n  if (label != (char *)0x0) {\n    label = dupstr(label);\n  }\n  (pcVar2->generic).label = label;\n  (pcVar2->editbox).shortcut = shortcut;\n  (pcVar2->editbox).percentwidth = ncolumns;\n  puVar6 = &stack0x00000024;\n  if (in_stack_00000020 == 0) {\n    n = 0;\n  }\n  else {\n    sVar8 = 0;\n    if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n  }\n  (pcVar2->editbox).password = n;\n  if (shortcut == '\0') {\n    pcVar5 = (char *)safemalloc(n,1);\n    (pcVar2->radio).shortcuts = pcVar5;\n    n = (pcVar2->editbox).password;\n  }\n  else {\n    (pcVar2->radio).shortcuts = (char *)0x0;\n  }\n  iVar10 = 0;\n  ppcVar3 = (char **)safemalloc(n,4);\n  (pcVar2->radio).buttons = ppcVar3;\n  piVar4 = (intorptr *)safemalloc((pcVar2->editbox).password,4);\n  (pcVar2->radio).buttondata = piVar4;\n  puVar9 = &stack0x00000020;\n  if (0 < (pcVar2->editbox).password) {\n    do {\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    } while (iVar10 < (pcVar2->editbox).password);\n  }\n  return pcVar2;\n}\n\n" comment (function_definition "control * ctrl_radiobuttons(controlset *s,char *label,char shortcut,int ncolumns,intorptr helpctx,\n                           handler_fn handler,intorptr context,...)\n\n{\n  int *piVar1;\n  control *pcVar2;\n  size_t n;\n  char **ppcVar3;\n  intorptr *piVar4;\n  char *pcVar5;\n  undefined1 *puVar6;\n  control **ppcVar7;\n  size_t sVar8;\n  undefined4 *puVar9;\n  int iVar10;\n  int in_stack_00000020;\n  \n  pcVar2 = (control *)safemalloc(1,0x3c);\n  iVar10 = s->ncontrols;\n  if (iVar10 < s->ctrlsize) {\n    ppcVar7 = s->ctrls;\n  }\n  else {\n    s->ctrlsize = iVar10 + 0x20U;\n    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);\n    iVar10 = s->ncontrols;\n    s->ctrls = ppcVar7;\n  }\n  s->ncontrols = iVar10 + 1;\n  ppcVar7[iVar10] = pcVar2;\n  iVar10 = s->ncolumns;\n  (pcVar2->generic).type = 2;\n  (pcVar2->generic).tabdelay = 0;\n  (pcVar2->generic).label = (char *)0x0;\n  (pcVar2->generic).column = (iVar10 + -1) * 0x10000;\n  (pcVar2->generic).helpctx = helpctx;\n  (pcVar2->generic).handler = handler;\n  (pcVar2->generic).context = context;\n  if (label != (char *)0x0) {\n    label = dupstr(label);\n  }\n  (pcVar2->generic).label = label;\n  (pcVar2->editbox).shortcut = shortcut;\n  (pcVar2->editbox).percentwidth = ncolumns;\n  puVar6 = &stack0x00000024;\n  if (in_stack_00000020 == 0) {\n    n = 0;\n  }\n  else {\n    sVar8 = 0;\n    if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n  }\n  (pcVar2->editbox).password = n;\n  if (shortcut == '\0') {\n    pcVar5 = (char *)safemalloc(n,1);\n    (pcVar2->radio).shortcuts = pcVar5;\n    n = (pcVar2->editbox).password;\n  }\n  else {\n    (pcVar2->radio).shortcuts = (char *)0x0;\n  }\n  iVar10 = 0;\n  ppcVar3 = (char **)safemalloc(n,4);\n  (pcVar2->radio).buttons = ppcVar3;\n  piVar4 = (intorptr *)safemalloc((pcVar2->editbox).password,4);\n  (pcVar2->radio).buttondata = piVar4;\n  puVar9 = &stack0x00000020;\n  if (0 < (pcVar2->editbox).password) {\n    do {\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    } while (iVar10 < (pcVar2->editbox).password);\n  }\n  return pcVar2;\n}" type_identifier (pointer_declarator "* ctrl_radiobuttons(controlset *s,char *label,char shortcut,int ncolumns,intorptr helpctx,\n                           handler_fn handler,intorptr context,...)" * (function_declarator "ctrl_radiobuttons(controlset *s,char *label,char shortcut,int ncolumns,intorptr helpctx,\n                           handler_fn handler,intorptr context,...)" identifier (parameter_list "(controlset *s,char *label,char shortcut,int ncolumns,intorptr helpctx,\n                           handler_fn handler,intorptr context,...)" ( (parameter_declaration "controlset *s" type_identifier (pointer_declarator "*s" * identifier)) , (parameter_declaration "char *label" primitive_type (pointer_declarator "*label" * identifier)) , (parameter_declaration "char shortcut" primitive_type identifier) , (parameter_declaration "int ncolumns" primitive_type identifier) , (parameter_declaration "intorptr helpctx" type_identifier identifier) , (parameter_declaration "handler_fn handler" type_identifier identifier) , (parameter_declaration "intorptr context" type_identifier identifier) , (variadic_parameter "..." ...) )))) (compound_statement "{\n  int *piVar1;\n  control *pcVar2;\n  size_t n;\n  char **ppcVar3;\n  intorptr *piVar4;\n  char *pcVar5;\n  undefined1 *puVar6;\n  control **ppcVar7;\n  size_t sVar8;\n  undefined4 *puVar9;\n  int iVar10;\n  int in_stack_00000020;\n  \n  pcVar2 = (control *)safemalloc(1,0x3c);\n  iVar10 = s->ncontrols;\n  if (iVar10 < s->ctrlsize) {\n    ppcVar7 = s->ctrls;\n  }\n  else {\n    s->ctrlsize = iVar10 + 0x20U;\n    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);\n    iVar10 = s->ncontrols;\n    s->ctrls = ppcVar7;\n  }\n  s->ncontrols = iVar10 + 1;\n  ppcVar7[iVar10] = pcVar2;\n  iVar10 = s->ncolumns;\n  (pcVar2->generic).type = 2;\n  (pcVar2->generic).tabdelay = 0;\n  (pcVar2->generic).label = (char *)0x0;\n  (pcVar2->generic).column = (iVar10 + -1) * 0x10000;\n  (pcVar2->generic).helpctx = helpctx;\n  (pcVar2->generic).handler = handler;\n  (pcVar2->generic).context = context;\n  if (label != (char *)0x0) {\n    label = dupstr(label);\n  }\n  (pcVar2->generic).label = label;\n  (pcVar2->editbox).shortcut = shortcut;\n  (pcVar2->editbox).percentwidth = ncolumns;\n  puVar6 = &stack0x00000024;\n  if (in_stack_00000020 == 0) {\n    n = 0;\n  }\n  else {\n    sVar8 = 0;\n    if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n  }\n  (pcVar2->editbox).password = n;\n  if (shortcut == '\0') {\n    pcVar5 = (char *)safemalloc(n,1);\n    (pcVar2->radio).shortcuts = pcVar5;\n    n = (pcVar2->editbox).password;\n  }\n  else {\n    (pcVar2->radio).shortcuts = (char *)0x0;\n  }\n  iVar10 = 0;\n  ppcVar3 = (char **)safemalloc(n,4);\n  (pcVar2->radio).buttons = ppcVar3;\n  piVar4 = (intorptr *)safemalloc((pcVar2->editbox).password,4);\n  (pcVar2->radio).buttondata = piVar4;\n  puVar9 = &stack0x00000020;\n  if (0 < (pcVar2->editbox).password) {\n    do {\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    } while (iVar10 < (pcVar2->editbox).password);\n  }\n  return pcVar2;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "control *pcVar2;" type_identifier (pointer_declarator "*pcVar2" * identifier) ;) (declaration "size_t n;" primitive_type identifier ;) (declaration "char **ppcVar3;" primitive_type (pointer_declarator "**ppcVar3" * (pointer_declarator "*ppcVar3" * identifier)) ;) (declaration "intorptr *piVar4;" type_identifier (pointer_declarator "*piVar4" * identifier) ;) (declaration "char *pcVar5;" primitive_type (pointer_declarator "*pcVar5" * identifier) ;) (declaration "undefined1 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "control **ppcVar7;" type_identifier (pointer_declarator "**ppcVar7" * (pointer_declarator "*ppcVar7" * identifier)) ;) (declaration "size_t sVar8;" primitive_type identifier ;) (declaration "undefined4 *puVar9;" type_identifier (pointer_declarator "*puVar9" * identifier) ;) (declaration "int iVar10;" primitive_type identifier ;) (declaration "int in_stack_00000020;" primitive_type identifier ;) (expression_statement "pcVar2 = (control *)safemalloc(1,0x3c);" (assignment_expression "pcVar2 = (control *)safemalloc(1,0x3c)" identifier = (cast_expression "(control *)safemalloc(1,0x3c)" ( (type_descriptor "control *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "safemalloc(1,0x3c)" identifier (argument_list "(1,0x3c)" ( number_literal , number_literal ))))) ;) (expression_statement "iVar10 = s->ncontrols;" (assignment_expression "iVar10 = s->ncontrols" identifier = (field_expression "s->ncontrols" identifier -> field_identifier)) ;) (if_statement "if (iVar10 < s->ctrlsize) {\n    ppcVar7 = s->ctrls;\n  }\n  else {\n    s->ctrlsize = iVar10 + 0x20U;\n    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);\n    iVar10 = s->ncontrols;\n    s->ctrls = ppcVar7;\n  }" if (parenthesized_expression "(iVar10 < s->ctrlsize)" ( (binary_expression "iVar10 < s->ctrlsize" identifier < (field_expression "s->ctrlsize" identifier -> field_identifier)) )) (compound_statement "{\n    ppcVar7 = s->ctrls;\n  }" { (expression_statement "ppcVar7 = s->ctrls;" (assignment_expression "ppcVar7 = s->ctrls" identifier = (field_expression "s->ctrls" identifier -> field_identifier)) ;) }) (else_clause "else {\n    s->ctrlsize = iVar10 + 0x20U;\n    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);\n    iVar10 = s->ncontrols;\n    s->ctrls = ppcVar7;\n  }" else (compound_statement "{\n    s->ctrlsize = iVar10 + 0x20U;\n    ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);\n    iVar10 = s->ncontrols;\n    s->ctrls = ppcVar7;\n  }" { (expression_statement "s->ctrlsize = iVar10 + 0x20U;" (assignment_expression "s->ctrlsize = iVar10 + 0x20U" (field_expression "s->ctrlsize" identifier -> field_identifier) = (binary_expression "iVar10 + 0x20U" identifier + number_literal)) ;) (expression_statement "ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4);" (assignment_expression "ppcVar7 = (control **)saferealloc(s->ctrls,iVar10 + 0x20U,4)" identifier = (cast_expression "(control **)saferealloc(s->ctrls,iVar10 + 0x20U,4)" ( (type_descriptor "control **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (call_expression "saferealloc(s->ctrls,iVar10 + 0x20U,4)" identifier (argument_list "(s->ctrls,iVar10 + 0x20U,4)" ( (field_expression "s->ctrls" identifier -> field_identifier) , (binary_expression "iVar10 + 0x20U" identifier + number_literal) , number_literal ))))) ;) (expression_statement "iVar10 = s->ncontrols;" (assignment_expression "iVar10 = s->ncontrols" identifier = (field_expression "s->ncontrols" identifier -> field_identifier)) ;) (expression_statement "s->ctrls = ppcVar7;" (assignment_expression "s->ctrls = ppcVar7" (field_expression "s->ctrls" identifier -> field_identifier) = identifier) ;) }))) (expression_statement "s->ncontrols = iVar10 + 1;" (assignment_expression "s->ncontrols = iVar10 + 1" (field_expression "s->ncontrols" identifier -> field_identifier) = (binary_expression "iVar10 + 1" identifier + number_literal)) ;) (expression_statement "ppcVar7[iVar10] = pcVar2;" (assignment_expression "ppcVar7[iVar10] = pcVar2" (subscript_expression "ppcVar7[iVar10]" identifier [ identifier ]) = identifier) ;) (expression_statement "iVar10 = s->ncolumns;" (assignment_expression "iVar10 = s->ncolumns" identifier = (field_expression "s->ncolumns" identifier -> field_identifier)) ;) (expression_statement "(pcVar2->generic).type = 2;" (assignment_expression "(pcVar2->generic).type = 2" (field_expression "(pcVar2->generic).type" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = number_literal) ;) (expression_statement "(pcVar2->generic).tabdelay = 0;" (assignment_expression "(pcVar2->generic).tabdelay = 0" (field_expression "(pcVar2->generic).tabdelay" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = number_literal) ;) (expression_statement "(pcVar2->generic).label = (char *)0x0;" (assignment_expression "(pcVar2->generic).label = (char *)0x0" (field_expression "(pcVar2->generic).label" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "(pcVar2->generic).column = (iVar10 + -1) * 0x10000;" (assignment_expression "(pcVar2->generic).column = (iVar10 + -1) * 0x10000" (field_expression "(pcVar2->generic).column" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = (binary_expression "(iVar10 + -1) * 0x10000" (parenthesized_expression "(iVar10 + -1)" ( (binary_expression "iVar10 + -1" identifier + number_literal) )) * number_literal)) ;) (expression_statement "(pcVar2->generic).helpctx = helpctx;" (assignment_expression "(pcVar2->generic).helpctx = helpctx" (field_expression "(pcVar2->generic).helpctx" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "(pcVar2->generic).handler = handler;" (assignment_expression "(pcVar2->generic).handler = handler" (field_expression "(pcVar2->generic).handler" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "(pcVar2->generic).context = context;" (assignment_expression "(pcVar2->generic).context = context" (field_expression "(pcVar2->generic).context" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (if_statement "if (label != (char *)0x0) {\n    label = dupstr(label);\n  }" if (parenthesized_expression "(label != (char *)0x0)" ( (binary_expression "label != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    label = dupstr(label);\n  }" { (expression_statement "label = dupstr(label);" (assignment_expression "label = dupstr(label)" identifier = (call_expression "dupstr(label)" identifier (argument_list "(label)" ( identifier )))) ;) })) (expression_statement "(pcVar2->generic).label = label;" (assignment_expression "(pcVar2->generic).label = label" (field_expression "(pcVar2->generic).label" (parenthesized_expression "(pcVar2->generic)" ( (field_expression "pcVar2->generic" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "(pcVar2->editbox).shortcut = shortcut;" (assignment_expression "(pcVar2->editbox).shortcut = shortcut" (field_expression "(pcVar2->editbox).shortcut" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "(pcVar2->editbox).percentwidth = ncolumns;" (assignment_expression "(pcVar2->editbox).percentwidth = ncolumns" (field_expression "(pcVar2->editbox).percentwidth" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "puVar6 = &stack0x00000024;" (assignment_expression "puVar6 = &stack0x00000024" identifier = (pointer_expression "&stack0x00000024" & identifier)) ;) (if_statement "if (in_stack_00000020 == 0) {\n    n = 0;\n  }\n  else {\n    sVar8 = 0;\n    if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n  }" if (parenthesized_expression "(in_stack_00000020 == 0)" ( (binary_expression "in_stack_00000020 == 0" identifier == number_literal) )) (compound_statement "{\n    n = 0;\n  }" { (expression_statement "n = 0;" (assignment_expression "n = 0" identifier = number_literal) ;) }) (else_clause "else {\n    sVar8 = 0;\n    if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n  }" else (compound_statement "{\n    sVar8 = 0;\n    if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n  }" { (expression_statement "sVar8 = 0;" (assignment_expression "sVar8 = 0" identifier = number_literal) ;) (if_statement "if (shortcut == '\0') {\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }" if (parenthesized_expression "(shortcut == '\0')" ( (binary_expression "shortcut == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n      do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }" { (do_statement "do {\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      } while (*piVar1 != 0);" do (compound_statement "{\n        n = sVar8 + 1;\n        if (*(int *)(puVar6 + 8) == 0) break;\n        piVar1 = (int *)(puVar6 + 0x14);\n        sVar8 = sVar8 + 2;\n        puVar6 = puVar6 + 0x18;\n        n = sVar8;\n      }" { (expression_statement "n = sVar8 + 1;" (assignment_expression "n = sVar8 + 1" identifier = (binary_expression "sVar8 + 1" identifier + number_literal)) ;) (if_statement "if (*(int *)(puVar6 + 8) == 0) break;" if (parenthesized_expression "(*(int *)(puVar6 + 8) == 0)" ( (binary_expression "*(int *)(puVar6 + 8) == 0" (pointer_expression "*(int *)(puVar6 + 8)" * (cast_expression "(int *)(puVar6 + 8)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 8)" ( (binary_expression "puVar6 + 8" identifier + number_literal) )))) == number_literal) )) (break_statement "break;" break ;)) (expression_statement "piVar1 = (int *)(puVar6 + 0x14);" (assignment_expression "piVar1 = (int *)(puVar6 + 0x14)" identifier = (cast_expression "(int *)(puVar6 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 0x14)" ( (binary_expression "puVar6 + 0x14" identifier + number_literal) )))) ;) (expression_statement "sVar8 = sVar8 + 2;" (assignment_expression "sVar8 = sVar8 + 2" identifier = (binary_expression "sVar8 + 2" identifier + number_literal)) ;) (expression_statement "puVar6 = puVar6 + 0x18;" (assignment_expression "puVar6 = puVar6 + 0x18" identifier = (binary_expression "puVar6 + 0x18" identifier + number_literal)) ;) (expression_statement "n = sVar8;" (assignment_expression "n = sVar8" identifier = identifier) ;) }) while (parenthesized_expression "(*piVar1 != 0)" ( (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" * identifier) != number_literal) )) ;) }) (else_clause "else {\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }" else (compound_statement "{\n      do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);\n    }" { (do_statement "do {\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      } while (*piVar1 != 0);" do (compound_statement "{\n        piVar1 = (int *)(puVar6 + 4);\n        sVar8 = sVar8 + 1;\n        puVar6 = puVar6 + 8;\n        n = sVar8;\n      }" { (expression_statement "piVar1 = (int *)(puVar6 + 4);" (assignment_expression "piVar1 = (int *)(puVar6 + 4)" identifier = (cast_expression "(int *)(puVar6 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 4)" ( (binary_expression "puVar6 + 4" identifier + number_literal) )))) ;) (expression_statement "sVar8 = sVar8 + 1;" (assignment_expression "sVar8 = sVar8 + 1" identifier = (binary_expression "sVar8 + 1" identifier + number_literal)) ;) (expression_statement "puVar6 = puVar6 + 8;" (assignment_expression "puVar6 = puVar6 + 8" identifier = (binary_expression "puVar6 + 8" identifier + number_literal)) ;) (expression_statement "n = sVar8;" (assignment_expression "n = sVar8" identifier = identifier) ;) }) while (parenthesized_expression "(*piVar1 != 0)" ( (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" * identifier) != number_literal) )) ;) }))) }))) (expression_statement "(pcVar2->editbox).password = n;" (assignment_expression "(pcVar2->editbox).password = n" (field_expression "(pcVar2->editbox).password" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (if_statement "if (shortcut == '\0') {\n    pcVar5 = (char *)safemalloc(n,1);\n    (pcVar2->radio).shortcuts = pcVar5;\n    n = (pcVar2->editbox).password;\n  }\n  else {\n    (pcVar2->radio).shortcuts = (char *)0x0;\n  }" if (parenthesized_expression "(shortcut == '\0')" ( (binary_expression "shortcut == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    pcVar5 = (char *)safemalloc(n,1);\n    (pcVar2->radio).shortcuts = pcVar5;\n    n = (pcVar2->editbox).password;\n  }" { (expression_statement "pcVar5 = (char *)safemalloc(n,1);" (assignment_expression "pcVar5 = (char *)safemalloc(n,1)" identifier = (cast_expression "(char *)safemalloc(n,1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "safemalloc(n,1)" identifier (argument_list "(n,1)" ( identifier , number_literal ))))) ;) (expression_statement "(pcVar2->radio).shortcuts = pcVar5;" (assignment_expression "(pcVar2->radio).shortcuts = pcVar5" (field_expression "(pcVar2->radio).shortcuts" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "n = (pcVar2->editbox).password;" (assignment_expression "n = (pcVar2->editbox).password" identifier = (field_expression "(pcVar2->editbox).password" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier)) ;) }) (else_clause "else {\n    (pcVar2->radio).shortcuts = (char *)0x0;\n  }" else (compound_statement "{\n    (pcVar2->radio).shortcuts = (char *)0x0;\n  }" { (expression_statement "(pcVar2->radio).shortcuts = (char *)0x0;" (assignment_expression "(pcVar2->radio).shortcuts = (char *)0x0" (field_expression "(pcVar2->radio).shortcuts" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) }))) (expression_statement "iVar10 = 0;" (assignment_expression "iVar10 = 0" identifier = number_literal) ;) (expression_statement "ppcVar3 = (char **)safemalloc(n,4);" (assignment_expression "ppcVar3 = (char **)safemalloc(n,4)" identifier = (cast_expression "(char **)safemalloc(n,4)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (call_expression "safemalloc(n,4)" identifier (argument_list "(n,4)" ( identifier , number_literal ))))) ;) (expression_statement "(pcVar2->radio).buttons = ppcVar3;" (assignment_expression "(pcVar2->radio).buttons = ppcVar3" (field_expression "(pcVar2->radio).buttons" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "piVar4 = (intorptr *)safemalloc((pcVar2->editbox).password,4);" (assignment_expression "piVar4 = (intorptr *)safemalloc((pcVar2->editbox).password,4)" identifier = (cast_expression "(intorptr *)safemalloc((pcVar2->editbox).password,4)" ( (type_descriptor "intorptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "safemalloc((pcVar2->editbox).password,4)" identifier (argument_list "((pcVar2->editbox).password,4)" ( (field_expression "(pcVar2->editbox).password" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier) , number_literal ))))) ;) (expression_statement "(pcVar2->radio).buttondata = piVar4;" (assignment_expression "(pcVar2->radio).buttondata = piVar4" (field_expression "(pcVar2->radio).buttondata" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "puVar9 = &stack0x00000020;" (assignment_expression "puVar9 = &stack0x00000020" identifier = (pointer_expression "&stack0x00000020" & identifier)) ;) (if_statement "if (0 < (pcVar2->editbox).password) {\n    do {\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    } while (iVar10 < (pcVar2->editbox).password);\n  }" if (parenthesized_expression "(0 < (pcVar2->editbox).password)" ( (binary_expression "0 < (pcVar2->editbox).password" number_literal < (field_expression "(pcVar2->editbox).password" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier)) )) (compound_statement "{\n    do {\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    } while (iVar10 < (pcVar2->editbox).password);\n  }" { (do_statement "do {\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    } while (iVar10 < (pcVar2->editbox).password);" do (compound_statement "{\n      while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }\n      (pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];\n      (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);\n      iVar10 = iVar10 + 1;\n      puVar9 = puVar9 + 3;\n    }" { (while_statement "while( true ) {\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        ppcVar3 = (pcVar2->radio).buttons;\n        pcVar5 = dupstr((char *)*puVar9);\n        ppcVar3[iVar10] = pcVar5;\n        if ((pcVar2->editbox).shortcut == '\0') break;\n        (pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);\n        iVar10 = iVar10 + 1;\n        puVar9 = puVar9 + 2;\n        if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }\n      }" { (expression_statement "ppcVar3 = (pcVar2->radio).buttons;" (assignment_expression "ppcVar3 = (pcVar2->radio).buttons" identifier = (field_expression "(pcVar2->radio).buttons" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier)) ;) (expression_statement "pcVar5 = dupstr((char *)*puVar9);" (assignment_expression "pcVar5 = dupstr((char *)*puVar9)" identifier = (call_expression "dupstr((char *)*puVar9)" identifier (argument_list "((char *)*puVar9)" ( (cast_expression "(char *)*puVar9" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar9" * identifier)) )))) ;) (expression_statement "ppcVar3[iVar10] = pcVar5;" (assignment_expression "ppcVar3[iVar10] = pcVar5" (subscript_expression "ppcVar3[iVar10]" identifier [ identifier ]) = identifier) ;) (if_statement "if ((pcVar2->editbox).shortcut == '\0') break;" if (parenthesized_expression "((pcVar2->editbox).shortcut == '\0')" ( (binary_expression "(pcVar2->editbox).shortcut == '\0'" (field_expression "(pcVar2->editbox).shortcut" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier) == (char_literal "'\0'" ' escape_sequence ')) )) (break_statement "break;" break ;)) (expression_statement "(pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1);" (assignment_expression "(pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 1)" (subscript_expression "(pcVar2->radio).buttondata[iVar10]" (field_expression "(pcVar2->radio).buttondata" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) [ identifier ]) = (pointer_expression "*(intorptr *)(puVar9 + 1)" * (cast_expression "(intorptr *)(puVar9 + 1)" ( (type_descriptor "intorptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar9 + 1)" ( (binary_expression "puVar9 + 1" identifier + number_literal) ))))) ;) (expression_statement "iVar10 = iVar10 + 1;" (assignment_expression "iVar10 = iVar10 + 1" identifier = (binary_expression "iVar10 + 1" identifier + number_literal)) ;) (expression_statement "puVar9 = puVar9 + 2;" (assignment_expression "puVar9 = puVar9 + 2" identifier = (binary_expression "puVar9 + 2" identifier + number_literal)) ;) (if_statement "if ((pcVar2->editbox).password <= iVar10) {\n          return pcVar2;\n        }" if (parenthesized_expression "((pcVar2->editbox).password <= iVar10)" ( (binary_expression "(pcVar2->editbox).password <= iVar10" (field_expression "(pcVar2->editbox).password" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier) <= identifier) )) (compound_statement "{\n          return pcVar2;\n        }" { (return_statement "return pcVar2;" return identifier ;) })) })) (expression_statement "(pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1];" (assignment_expression "(pcVar2->radio).shortcuts[iVar10] = (char)puVar9[1]" (subscript_expression "(pcVar2->radio).shortcuts[iVar10]" (field_expression "(pcVar2->radio).shortcuts" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) [ identifier ]) = (cast_expression "(char)puVar9[1]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "puVar9[1]" identifier [ number_literal ]))) ;) (expression_statement "(pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2);" (assignment_expression "(pcVar2->radio).buttondata[iVar10] = *(intorptr *)(puVar9 + 2)" (subscript_expression "(pcVar2->radio).buttondata[iVar10]" (field_expression "(pcVar2->radio).buttondata" (parenthesized_expression "(pcVar2->radio)" ( (field_expression "pcVar2->radio" identifier -> field_identifier) )) . field_identifier) [ identifier ]) = (pointer_expression "*(intorptr *)(puVar9 + 2)" * (cast_expression "(intorptr *)(puVar9 + 2)" ( (type_descriptor "intorptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar9 + 2)" ( (binary_expression "puVar9 + 2" identifier + number_literal) ))))) ;) (expression_statement "iVar10 = iVar10 + 1;" (assignment_expression "iVar10 = iVar10 + 1" identifier = (binary_expression "iVar10 + 1" identifier + number_literal)) ;) (expression_statement "puVar9 = puVar9 + 3;" (assignment_expression "puVar9 = puVar9 + 3" identifier = (binary_expression "puVar9 + 3" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar10 < (pcVar2->editbox).password)" ( (binary_expression "iVar10 < (pcVar2->editbox).password" identifier < (field_expression "(pcVar2->editbox).password" (parenthesized_expression "(pcVar2->editbox)" ( (field_expression "pcVar2->editbox" identifier -> field_identifier) )) . field_identifier)) )) ;) })) (return_statement "return pcVar2;" return identifier ;) })))
(translation_unit "undefined4 *\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)\n\n{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}\n\n" (function_definition "undefined4 *\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)\n\n{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}" type_identifier (pointer_declarator "*\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" * (function_declarator "FUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" identifier (parameter_list "(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "char param_3" primitive_type identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) , (parameter_declaration "undefined4 param_5" type_identifier identifier) , (parameter_declaration "undefined4 param_6" type_identifier identifier) , (parameter_declaration "undefined4 param_7" type_identifier identifier) , (parameter_declaration "int param_8" primitive_type identifier) )))) (compound_statement "{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "undefined4 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (declaration "undefined1 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "undefined4 *puVar7;" type_identifier (pointer_declarator "*puVar7" * identifier) ;) (expression_statement "puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);" (assignment_expression "puVar2 = (undefined4 *)FUN_000313e0(1,0x3c)" identifier = (cast_expression "(undefined4 *)FUN_000313e0(1,0x3c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_000313e0(1,0x3c)" identifier (argument_list "(1,0x3c)" ( number_literal , number_literal ))))) ;) (expression_statement "iVar3 = *(int *)(param_1 + 0x10);" (assignment_expression "iVar3 = *(int *)(param_1 + 0x10)" identifier = (pointer_expression "*(int *)(param_1 + 0x10)" * (cast_expression "(int *)(param_1 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) (if_statement "if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" if (parenthesized_expression "(iVar3 < *(int *)(param_1 + 0x14))" ( (binary_expression "iVar3 < *(int *)(param_1 + 0x14)" identifier < (pointer_expression "*(int *)(param_1 + 0x14)" * (cast_expression "(int *)(param_1 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    iVar6 = *(int *)(param_1 + 0x18);\n  }" { (expression_statement "iVar6 = *(int *)(param_1 + 0x18);" (assignment_expression "iVar6 = *(int *)(param_1 + 0x18)" identifier = (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) ))))) ;) }) (else_clause "else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" else (compound_statement "{\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" { (expression_statement "*(int *)(param_1 + 0x14) = iVar3 + 0x20;" (assignment_expression "*(int *)(param_1 + 0x14) = iVar3 + 0x20" (pointer_expression "*(int *)(param_1 + 0x14)" * (cast_expression "(int *)(param_1 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) )))) = (binary_expression "iVar3 + 0x20" identifier + number_literal)) ;) (expression_statement "iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);" (assignment_expression "iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" identifier = (call_expression "FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" identifier (argument_list "(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" ( (pointer_expression "*(undefined4 *)(param_1 + 0x18)" * (cast_expression "(undefined4 *)(param_1 + 0x18)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) , (binary_expression "iVar3 + 0x20" identifier + number_literal) , number_literal )))) ;) (expression_statement "iVar3 = *(int *)(param_1 + 0x10);" (assignment_expression "iVar3 = *(int *)(param_1 + 0x10)" identifier = (pointer_expression "*(int *)(param_1 + 0x10)" * (cast_expression "(int *)(param_1 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) (expression_statement "*(int *)(param_1 + 0x18) = iVar6;" (assignment_expression "*(int *)(param_1 + 0x18) = iVar6" (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) = identifier) ;) }))) (expression_statement "*(int *)(param_1 + 0x10) = iVar3 + 1;" (assignment_expression "*(int *)(param_1 + 0x10) = iVar3 + 1" (pointer_expression "*(int *)(param_1 + 0x10)" * (cast_expression "(int *)(param_1 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (expression_statement "*(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;" (assignment_expression "*(undefined4 **)(iVar6 + iVar3 * 4) = puVar2" (pointer_expression "*(undefined4 **)(iVar6 + iVar3 * 4)" * (cast_expression "(undefined4 **)(iVar6 + iVar3 * 4)" ( (type_descriptor "undefined4 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(iVar6 + iVar3 * 4)" ( (binary_expression "iVar6 + iVar3 * 4" identifier + (binary_expression "iVar3 * 4" identifier * number_literal)) )))) = identifier) ;) (expression_statement "iVar3 = *(int *)(param_1 + 0xc);" (assignment_expression "iVar3 = *(int *)(param_1 + 0xc)" identifier = (pointer_expression "*(int *)(param_1 + 0xc)" * (cast_expression "(int *)(param_1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) ))))) ;) (expression_statement "*puVar2 = 2;" (assignment_expression "*puVar2 = 2" (pointer_expression "*puVar2" * identifier) = number_literal) ;) (expression_statement "puVar2[2] = 0;" (assignment_expression "puVar2[2] = 0" (subscript_expression "puVar2[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "puVar2[1] = 0;" (assignment_expression "puVar2[1] = 0" (subscript_expression "puVar2[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "puVar2[3] = (iVar3 + -1) * 0x10000;" (assignment_expression "puVar2[3] = (iVar3 + -1) * 0x10000" (subscript_expression "puVar2[3]" identifier [ number_literal ]) = (binary_expression "(iVar3 + -1) * 0x10000" (parenthesized_expression "(iVar3 + -1)" ( (binary_expression "iVar3 + -1" identifier + number_literal) )) * number_literal)) ;) (expression_statement "puVar2[6] = param_5;" (assignment_expression "puVar2[6] = param_5" (subscript_expression "puVar2[6]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar2[4] = param_6;" (assignment_expression "puVar2[4] = param_6" (subscript_expression "puVar2[4]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar2[5] = param_7;" (assignment_expression "puVar2[5] = param_7" (subscript_expression "puVar2[5]" identifier [ number_literal ]) = identifier) ;) (if_statement "if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }" if (parenthesized_expression "(param_2 != 0)" ( (binary_expression "param_2 != 0" identifier != number_literal) )) (compound_statement "{\n    param_2 = FUN_00030420(param_2);\n  }" { (expression_statement "param_2 = FUN_00030420(param_2);" (assignment_expression "param_2 = FUN_00030420(param_2)" identifier = (call_expression "FUN_00030420(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) })) (expression_statement "puVar2[1] = param_2;" (assignment_expression "puVar2[1] = param_2" (subscript_expression "puVar2[1]" identifier [ number_literal ]) = identifier) ;) (expression_statement "*(char *)(puVar2 + 7) = param_3;" (assignment_expression "*(char *)(puVar2 + 7) = param_3" (pointer_expression "*(char *)(puVar2 + 7)" * (cast_expression "(char *)(puVar2 + 7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2 + 7)" ( (binary_expression "puVar2 + 7" identifier + number_literal) )))) = identifier) ;) (expression_statement "puVar2[8] = param_4;" (assignment_expression "puVar2[8] = param_4" (subscript_expression "puVar2[8]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar5 = &stack0x00000024;" (assignment_expression "puVar5 = &stack0x00000024" identifier = (pointer_expression "&stack0x00000024" & identifier)) ;) (if_statement "if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" if (parenthesized_expression "(param_8 == 0)" ( (binary_expression "param_8 == 0" identifier == number_literal) )) (compound_statement "{\n    iVar3 = 0;\n  }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" else (compound_statement "{\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (if_statement "if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" if (parenthesized_expression "(param_3 == '\0')" ( (binary_expression "param_3 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" { (do_statement "do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);" do (compound_statement "{\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      }" { (expression_statement "iVar3 = iVar6 + 1;" (assignment_expression "iVar3 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (if_statement "if (*(int *)(puVar5 + 8) == 0) break;" if (parenthesized_expression "(*(int *)(puVar5 + 8) == 0)" ( (binary_expression "*(int *)(puVar5 + 8) == 0" (pointer_expression "*(int *)(puVar5 + 8)" * (cast_expression "(int *)(puVar5 + 8)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar5 + 8)" ( (binary_expression "puVar5 + 8" identifier + number_literal) )))) == number_literal) )) (break_statement "break;" break ;)) (expression_statement "piVar1 = (int *)(puVar5 + 0x14);" (assignment_expression "piVar1 = (int *)(puVar5 + 0x14)" identifier = (cast_expression "(int *)(puVar5 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar5 + 0x14)" ( (binary_expression "puVar5 + 0x14" identifier + number_literal) )))) ;) (expression_statement "iVar6 = iVar6 + 2;" (assignment_expression "iVar6 = iVar6 + 2" identifier = (binary_expression "iVar6 + 2" identifier + number_literal)) ;) (expression_statement "puVar5 = puVar5 + 0x18;" (assignment_expression "puVar5 = puVar5 + 0x18" identifier = (binary_expression "puVar5 + 0x18" identifier + number_literal)) ;) (expression_statement "iVar3 = iVar6;" (assignment_expression "iVar3 = iVar6" identifier = identifier) ;) }) while (parenthesized_expression "(*piVar1 != 0)" ( (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" * identifier) != number_literal) )) ;) }) (else_clause "else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" else (compound_statement "{\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" { (do_statement "do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);" do (compound_statement "{\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      }" { (expression_statement "piVar1 = (int *)(puVar5 + 4);" (assignment_expression "piVar1 = (int *)(puVar5 + 4)" identifier = (cast_expression "(int *)(puVar5 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar5 + 4)" ( (binary_expression "puVar5 + 4" identifier + number_literal) )))) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "puVar5 = puVar5 + 8;" (assignment_expression "puVar5 = puVar5 + 8" identifier = (binary_expression "puVar5 + 8" identifier + number_literal)) ;) (expression_statement "iVar3 = iVar6;" (assignment_expression "iVar3 = iVar6" identifier = identifier) ;) }) while (parenthesized_expression "(*piVar1 != 0)" ( (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" * identifier) != number_literal) )) ;) }))) }))) (expression_statement "puVar2[9] = iVar3;" (assignment_expression "puVar2[9] = iVar3" (subscript_expression "puVar2[9]" identifier [ number_literal ]) = identifier) ;) (if_statement "if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }" if (parenthesized_expression "(param_3 == '\0')" ( (binary_expression "param_3 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }" { (expression_statement "uVar4 = FUN_000313e0(iVar3,1);" (assignment_expression "uVar4 = FUN_000313e0(iVar3,1)" identifier = (call_expression "FUN_000313e0(iVar3,1)" identifier (argument_list "(iVar3,1)" ( identifier , number_literal )))) ;) (expression_statement "puVar2[0xb] = uVar4;" (assignment_expression "puVar2[0xb] = uVar4" (subscript_expression "puVar2[0xb]" identifier [ number_literal ]) = identifier) ;) (expression_statement "iVar3 = puVar2[9];" (assignment_expression "iVar3 = puVar2[9]" identifier = (subscript_expression "puVar2[9]" identifier [ number_literal ])) ;) }) (else_clause "else {\n    puVar2[0xb] = 0;\n  }" else (compound_statement "{\n    puVar2[0xb] = 0;\n  }" { (expression_statement "puVar2[0xb] = 0;" (assignment_expression "puVar2[0xb] = 0" (subscript_expression "puVar2[0xb]" identifier [ number_literal ]) = number_literal) ;) }))) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "uVar4 = FUN_000313e0(iVar3,4);" (assignment_expression "uVar4 = FUN_000313e0(iVar3,4)" identifier = (call_expression "FUN_000313e0(iVar3,4)" identifier (argument_list "(iVar3,4)" ( identifier , number_literal )))) ;) (expression_statement "puVar2[10] = uVar4;" (assignment_expression "puVar2[10] = uVar4" (subscript_expression "puVar2[10]" identifier [ number_literal ]) = identifier) ;) (expression_statement "uVar4 = FUN_000313e0(puVar2[9],4);" (assignment_expression "uVar4 = FUN_000313e0(puVar2[9],4)" identifier = (call_expression "FUN_000313e0(puVar2[9],4)" identifier (argument_list "(puVar2[9],4)" ( (subscript_expression "puVar2[9]" identifier [ number_literal ]) , number_literal )))) ;) (expression_statement "puVar2[0xc] = uVar4;" (assignment_expression "puVar2[0xc] = uVar4" (subscript_expression "puVar2[0xc]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar7 = &param_8;" (assignment_expression "puVar7 = &param_8" identifier = (pointer_expression "&param_8" & identifier)) ;) (if_statement "if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }" if (parenthesized_expression "(0 < (int)puVar2[9])" ( (binary_expression "0 < (int)puVar2[9]" number_literal < (cast_expression "(int)puVar2[9]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "puVar2[9]" identifier [ number_literal ]))) )) (compound_statement "{\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }" { (do_statement "do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);" do (compound_statement "{\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    }" { (while_statement "while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }" { (expression_statement "iVar3 = puVar2[10];" (assignment_expression "iVar3 = puVar2[10]" identifier = (subscript_expression "puVar2[10]" identifier [ number_literal ])) ;) (expression_statement "uVar4 = FUN_00030420(*puVar7);" (assignment_expression "uVar4 = FUN_00030420(*puVar7)" identifier = (call_expression "FUN_00030420(*puVar7)" identifier (argument_list "(*puVar7)" ( (pointer_expression "*puVar7" * identifier) )))) ;) (expression_statement "*(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;" (assignment_expression "*(undefined4 *)(iVar3 + iVar6 * 4) = uVar4" (pointer_expression "*(undefined4 *)(iVar3 + iVar6 * 4)" * (cast_expression "(undefined4 *)(iVar3 + iVar6 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar6 * 4)" ( (binary_expression "iVar3 + iVar6 * 4" identifier + (binary_expression "iVar6 * 4" identifier * number_literal)) )))) = identifier) ;) (if_statement "if (*(char *)(puVar2 + 7) == '\0') break;" if (parenthesized_expression "(*(char *)(puVar2 + 7) == '\0')" ( (binary_expression "*(char *)(puVar2 + 7) == '\0'" (pointer_expression "*(char *)(puVar2 + 7)" * (cast_expression "(char *)(puVar2 + 7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2 + 7)" ( (binary_expression "puVar2 + 7" identifier + number_literal) )))) == (char_literal "'\0'" ' escape_sequence ')) )) (break_statement "break;" break ;)) (expression_statement "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];" (assignment_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1]" (pointer_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4)" * (cast_expression "(undefined4 *)(puVar2[0xc] + iVar6 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2[0xc] + iVar6 * 4)" ( (binary_expression "puVar2[0xc] + iVar6 * 4" (subscript_expression "puVar2[0xc]" identifier [ number_literal ]) + (binary_expression "iVar6 * 4" identifier * number_literal)) )))) = (subscript_expression "puVar7[1]" identifier [ number_literal ])) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "puVar7 = puVar7 + 2;" (assignment_expression "puVar7 = puVar7 + 2" identifier = (binary_expression "puVar7 + 2" identifier + number_literal)) ;) (if_statement "if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }" if (parenthesized_expression "((int)puVar2[9] <= iVar6)" ( (binary_expression "(int)puVar2[9] <= iVar6" (cast_expression "(int)puVar2[9]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "puVar2[9]" identifier [ number_literal ])) <= identifier) )) (compound_statement "{\n          return puVar2;\n        }" { (return_statement "return puVar2;" return identifier ;) })) })) (expression_statement "*(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];" (assignment_expression "*(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1]" (pointer_expression "*(char *)(puVar2[0xb] + iVar6)" * (cast_expression "(char *)(puVar2[0xb] + iVar6)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2[0xb] + iVar6)" ( (binary_expression "puVar2[0xb] + iVar6" (subscript_expression "puVar2[0xb]" identifier [ number_literal ]) + identifier) )))) = (cast_expression "(char)puVar7[1]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "puVar7[1]" identifier [ number_literal ]))) ;) (expression_statement "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];" (assignment_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2]" (pointer_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4)" * (cast_expression "(undefined4 *)(puVar2[0xc] + iVar6 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar2[0xc] + iVar6 * 4)" ( (binary_expression "puVar2[0xc] + iVar6 * 4" (subscript_expression "puVar2[0xc]" identifier [ number_literal ]) + (binary_expression "iVar6 * 4" identifier * number_literal)) )))) = (subscript_expression "puVar7[2]" identifier [ number_literal ])) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "puVar7 = puVar7 + 3;" (assignment_expression "puVar7 = puVar7 + 3" identifier = (binary_expression "puVar7 + 3" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar6 < (int)puVar2[9])" ( (binary_expression "iVar6 < (int)puVar2[9]" identifier < (cast_expression "(int)puVar2[9]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "puVar2[9]" identifier [ number_literal ]))) )) ;) })) (return_statement "return puVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) )))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( LIT , LIT ))))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , (binary_expression IDENT + LIT) , LIT )))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) }))) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression IDENT * LIT)) )))) = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression (parenthesized_expression ( (binary_expression IDENT + LIT) )) * LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) })) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression & IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' escape_sequence ')) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != LIT) )) ;) }) (else_clause else (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != LIT) )) ;) }))) }))) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) }))) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , LIT )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression & IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ]))) )) (compound_statement { (do_statement do (compound_statement { (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * IDENT) )))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression IDENT * LIT)) )))) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == (char_literal ' escape_sequence ')) )) (break_statement break ;)) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + (binary_expression IDENT * LIT)) )))) = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ])) <= IDENT) )) (compound_statement { (return_statement return IDENT ;) })) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + IDENT) )))) = (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ]))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + (binary_expression IDENT * LIT)) )))) = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ]))) )) ;) })) (return_statement return IDENT ;) })))
(function_definition "undefined4 *\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)\n\n{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}" (type_identifier "undefined4") (pointer_declarator "*\nFUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" (* "*") (function_declarator "FUN_0002a040(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" (identifier "FUN_0002a040") (parameter_list "(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,\n            undefined4 param_6,undefined4 param_7,int param_8)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) (, ",") (parameter_declaration "char param_3" (primitive_type "char") (identifier "param_3")) (, ",") (parameter_declaration "undefined4 param_4" (type_identifier "undefined4") (identifier "param_4")) (, ",") (parameter_declaration "undefined4 param_5" (type_identifier "undefined4") (identifier "param_5")) (, ",") (parameter_declaration "undefined4 param_6" (type_identifier "undefined4") (identifier "param_6")) (, ",") (parameter_declaration "undefined4 param_7" (type_identifier "undefined4") (identifier "param_7")) (, ",") (parameter_declaration "int param_8" (primitive_type "int") (identifier "param_8")) () ")")))) (compound_statement "{\n  int *piVar1;\n  undefined4 *puVar2;\n  int iVar3;\n  undefined4 uVar4;\n  undefined1 *puVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);\n  iVar3 = *(int *)(param_1 + 0x10);\n  if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }\n  *(int *)(param_1 + 0x10) = iVar3 + 1;\n  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;\n  iVar3 = *(int *)(param_1 + 0xc);\n  *puVar2 = 2;\n  puVar2[2] = 0;\n  puVar2[1] = 0;\n  puVar2[3] = (iVar3 + -1) * 0x10000;\n  puVar2[6] = param_5;\n  puVar2[4] = param_6;\n  puVar2[5] = param_7;\n  if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }\n  puVar2[1] = param_2;\n  *(char *)(puVar2 + 7) = param_3;\n  puVar2[8] = param_4;\n  puVar5 = &stack0x00000024;\n  if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }\n  puVar2[9] = iVar3;\n  if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }\n  iVar6 = 0;\n  uVar4 = FUN_000313e0(iVar3,4);\n  puVar2[10] = uVar4;\n  uVar4 = FUN_000313e0(puVar2[9],4);\n  puVar2[0xc] = uVar4;\n  puVar7 = &param_8;\n  if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }\n  return puVar2;\n}" ({ "{") (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "undefined4 *puVar2;" (type_identifier "undefined4") (pointer_declarator "*puVar2" (* "*") (identifier "puVar2")) (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "undefined4 uVar4;" (type_identifier "undefined4") (identifier "uVar4") (; ";")) (declaration "undefined1 *puVar5;" (type_identifier "undefined1") (pointer_declarator "*puVar5" (* "*") (identifier "puVar5")) (; ";")) (declaration "int iVar6;" (primitive_type "int") (identifier "iVar6") (; ";")) (declaration "undefined4 *puVar7;" (type_identifier "undefined4") (pointer_declarator "*puVar7" (* "*") (identifier "puVar7")) (; ";")) (expression_statement "puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);" (assignment_expression "puVar2 = (undefined4 *)FUN_000313e0(1,0x3c)" (identifier "puVar2") (= "=") (cast_expression "(undefined4 *)FUN_000313e0(1,0x3c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_000313e0(1,0x3c)" (identifier "FUN_000313e0") (argument_list "(1,0x3c)" (( "(") (number_literal "1") (, ",") (number_literal "0x3c") () ")"))))) (; ";")) (expression_statement "iVar3 = *(int *)(param_1 + 0x10);" (assignment_expression "iVar3 = *(int *)(param_1 + 0x10)" (identifier "iVar3") (= "=") (pointer_expression "*(int *)(param_1 + 0x10)" (* "*") (cast_expression "(int *)(param_1 + 0x10)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")"))))) (; ";")) (if_statement "if (iVar3 < *(int *)(param_1 + 0x14)) {\n    iVar6 = *(int *)(param_1 + 0x18);\n  }\n  else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" (if "if") (parenthesized_expression "(iVar3 < *(int *)(param_1 + 0x14))" (( "(") (binary_expression "iVar3 < *(int *)(param_1 + 0x14)" (identifier "iVar3") (< "<") (pointer_expression "*(int *)(param_1 + 0x14)" (* "*") (cast_expression "(int *)(param_1 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x14)" (( "(") (binary_expression "param_1 + 0x14" (identifier "param_1") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n    iVar6 = *(int *)(param_1 + 0x18);\n  }" ({ "{") (expression_statement "iVar6 = *(int *)(param_1 + 0x18);" (assignment_expression "iVar6 = *(int *)(param_1 + 0x18)" (identifier "iVar6") (= "=") (pointer_expression "*(int *)(param_1 + 0x18)" (* "*") (cast_expression "(int *)(param_1 + 0x18)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")"))))) (; ";")) (} "}")) (else_clause "else {\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" (else "else") (compound_statement "{\n    *(int *)(param_1 + 0x14) = iVar3 + 0x20;\n    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);\n    iVar3 = *(int *)(param_1 + 0x10);\n    *(int *)(param_1 + 0x18) = iVar6;\n  }" ({ "{") (expression_statement "*(int *)(param_1 + 0x14) = iVar3 + 0x20;" (assignment_expression "*(int *)(param_1 + 0x14) = iVar3 + 0x20" (pointer_expression "*(int *)(param_1 + 0x14)" (* "*") (cast_expression "(int *)(param_1 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x14)" (( "(") (binary_expression "param_1 + 0x14" (identifier "param_1") (+ "+") (number_literal "0x14")) () ")")))) (= "=") (binary_expression "iVar3 + 0x20" (identifier "iVar3") (+ "+") (number_literal "0x20"))) (; ";")) (expression_statement "iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);" (assignment_expression "iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" (identifier "iVar6") (= "=") (call_expression "FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" (identifier "FUN_000314a0") (argument_list "(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4)" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0x18)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x18)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")")))) (, ",") (binary_expression "iVar3 + 0x20" (identifier "iVar3") (+ "+") (number_literal "0x20")) (, ",") (number_literal "4") () ")")))) (; ";")) (expression_statement "iVar3 = *(int *)(param_1 + 0x10);" (assignment_expression "iVar3 = *(int *)(param_1 + 0x10)" (identifier "iVar3") (= "=") (pointer_expression "*(int *)(param_1 + 0x10)" (* "*") (cast_expression "(int *)(param_1 + 0x10)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")"))))) (; ";")) (expression_statement "*(int *)(param_1 + 0x18) = iVar6;" (assignment_expression "*(int *)(param_1 + 0x18) = iVar6" (pointer_expression "*(int *)(param_1 + 0x18)" (* "*") (cast_expression "(int *)(param_1 + 0x18)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")")))) (= "=") (identifier "iVar6")) (; ";")) (} "}")))) (expression_statement "*(int *)(param_1 + 0x10) = iVar3 + 1;" (assignment_expression "*(int *)(param_1 + 0x10) = iVar3 + 1" (pointer_expression "*(int *)(param_1 + 0x10)" (* "*") (cast_expression "(int *)(param_1 + 0x10)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (= "=") (binary_expression "iVar3 + 1" (identifier "iVar3") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "*(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;" (assignment_expression "*(undefined4 **)(iVar6 + iVar3 * 4) = puVar2" (pointer_expression "*(undefined4 **)(iVar6 + iVar3 * 4)" (* "*") (cast_expression "(undefined4 **)(iVar6 + iVar3 * 4)" (( "(") (type_descriptor "undefined4 **" (type_identifier "undefined4") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(iVar6 + iVar3 * 4)" (( "(") (binary_expression "iVar6 + iVar3 * 4" (identifier "iVar6") (+ "+") (binary_expression "iVar3 * 4" (identifier "iVar3") (* "*") (number_literal "4"))) () ")")))) (= "=") (identifier "puVar2")) (; ";")) (expression_statement "iVar3 = *(int *)(param_1 + 0xc);" (assignment_expression "iVar3 = *(int *)(param_1 + 0xc)" (identifier "iVar3") (= "=") (pointer_expression "*(int *)(param_1 + 0xc)" (* "*") (cast_expression "(int *)(param_1 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")"))))) (; ";")) (expression_statement "*puVar2 = 2;" (assignment_expression "*puVar2 = 2" (pointer_expression "*puVar2" (* "*") (identifier "puVar2")) (= "=") (number_literal "2")) (; ";")) (expression_statement "puVar2[2] = 0;" (assignment_expression "puVar2[2] = 0" (subscript_expression "puVar2[2]" (identifier "puVar2") ([ "[") (number_literal "2") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "puVar2[1] = 0;" (assignment_expression "puVar2[1] = 0" (subscript_expression "puVar2[1]" (identifier "puVar2") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "puVar2[3] = (iVar3 + -1) * 0x10000;" (assignment_expression "puVar2[3] = (iVar3 + -1) * 0x10000" (subscript_expression "puVar2[3]" (identifier "puVar2") ([ "[") (number_literal "3") (] "]")) (= "=") (binary_expression "(iVar3 + -1) * 0x10000" (parenthesized_expression "(iVar3 + -1)" (( "(") (binary_expression "iVar3 + -1" (identifier "iVar3") (+ "+") (number_literal "-1")) () ")")) (* "*") (number_literal "0x10000"))) (; ";")) (expression_statement "puVar2[6] = param_5;" (assignment_expression "puVar2[6] = param_5" (subscript_expression "puVar2[6]" (identifier "puVar2") ([ "[") (number_literal "6") (] "]")) (= "=") (identifier "param_5")) (; ";")) (expression_statement "puVar2[4] = param_6;" (assignment_expression "puVar2[4] = param_6" (subscript_expression "puVar2[4]" (identifier "puVar2") ([ "[") (number_literal "4") (] "]")) (= "=") (identifier "param_6")) (; ";")) (expression_statement "puVar2[5] = param_7;" (assignment_expression "puVar2[5] = param_7" (subscript_expression "puVar2[5]" (identifier "puVar2") ([ "[") (number_literal "5") (] "]")) (= "=") (identifier "param_7")) (; ";")) (if_statement "if (param_2 != 0) {\n    param_2 = FUN_00030420(param_2);\n  }" (if "if") (parenthesized_expression "(param_2 != 0)" (( "(") (binary_expression "param_2 != 0" (identifier "param_2") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    param_2 = FUN_00030420(param_2);\n  }" ({ "{") (expression_statement "param_2 = FUN_00030420(param_2);" (assignment_expression "param_2 = FUN_00030420(param_2)" (identifier "param_2") (= "=") (call_expression "FUN_00030420(param_2)" (identifier "FUN_00030420") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (} "}"))) (expression_statement "puVar2[1] = param_2;" (assignment_expression "puVar2[1] = param_2" (subscript_expression "puVar2[1]" (identifier "puVar2") ([ "[") (number_literal "1") (] "]")) (= "=") (identifier "param_2")) (; ";")) (expression_statement "*(char *)(puVar2 + 7) = param_3;" (assignment_expression "*(char *)(puVar2 + 7) = param_3" (pointer_expression "*(char *)(puVar2 + 7)" (* "*") (cast_expression "(char *)(puVar2 + 7)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar2 + 7)" (( "(") (binary_expression "puVar2 + 7" (identifier "puVar2") (+ "+") (number_literal "7")) () ")")))) (= "=") (identifier "param_3")) (; ";")) (expression_statement "puVar2[8] = param_4;" (assignment_expression "puVar2[8] = param_4" (subscript_expression "puVar2[8]" (identifier "puVar2") ([ "[") (number_literal "8") (] "]")) (= "=") (identifier "param_4")) (; ";")) (expression_statement "puVar5 = &stack0x00000024;" (assignment_expression "puVar5 = &stack0x00000024" (identifier "puVar5") (= "=") (pointer_expression "&stack0x00000024" (& "&") (identifier "stack0x00000024"))) (; ";")) (if_statement "if (param_8 == 0) {\n    iVar3 = 0;\n  }\n  else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" (if "if") (parenthesized_expression "(param_8 == 0)" (( "(") (binary_expression "param_8 == 0" (identifier "param_8") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    iVar3 = 0;\n  }" ({ "{") (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" (identifier "iVar3") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" (else "else") (compound_statement "{\n    iVar6 = 0;\n    if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n  }" ({ "{") (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" (identifier "iVar6") (= "=") (number_literal "0")) (; ";")) (if_statement "if (param_3 == '\0') {\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }\n    else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" (if "if") (parenthesized_expression "(param_3 == '\0')" (( "(") (binary_expression "param_3 == '\0'" (identifier "param_3") (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n      do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" ({ "{") (do_statement "do {\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);" (do "do") (compound_statement "{\n        iVar3 = iVar6 + 1;\n        if (*(int *)(puVar5 + 8) == 0) break;\n        piVar1 = (int *)(puVar5 + 0x14);\n        iVar6 = iVar6 + 2;\n        puVar5 = puVar5 + 0x18;\n        iVar3 = iVar6;\n      }" ({ "{") (expression_statement "iVar3 = iVar6 + 1;" (assignment_expression "iVar3 = iVar6 + 1" (identifier "iVar3") (= "=") (binary_expression "iVar6 + 1" (identifier "iVar6") (+ "+") (number_literal "1"))) (; ";")) (if_statement "if (*(int *)(puVar5 + 8) == 0) break;" (if "if") (parenthesized_expression "(*(int *)(puVar5 + 8) == 0)" (( "(") (binary_expression "*(int *)(puVar5 + 8) == 0" (pointer_expression "*(int *)(puVar5 + 8)" (* "*") (cast_expression "(int *)(puVar5 + 8)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar5 + 8)" (( "(") (binary_expression "puVar5 + 8" (identifier "puVar5") (+ "+") (number_literal "8")) () ")")))) (== "==") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "piVar1 = (int *)(puVar5 + 0x14);" (assignment_expression "piVar1 = (int *)(puVar5 + 0x14)" (identifier "piVar1") (= "=") (cast_expression "(int *)(puVar5 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar5 + 0x14)" (( "(") (binary_expression "puVar5 + 0x14" (identifier "puVar5") (+ "+") (number_literal "0x14")) () ")")))) (; ";")) (expression_statement "iVar6 = iVar6 + 2;" (assignment_expression "iVar6 = iVar6 + 2" (identifier "iVar6") (= "=") (binary_expression "iVar6 + 2" (identifier "iVar6") (+ "+") (number_literal "2"))) (; ";")) (expression_statement "puVar5 = puVar5 + 0x18;" (assignment_expression "puVar5 = puVar5 + 0x18" (identifier "puVar5") (= "=") (binary_expression "puVar5 + 0x18" (identifier "puVar5") (+ "+") (number_literal "0x18"))) (; ";")) (expression_statement "iVar3 = iVar6;" (assignment_expression "iVar3 = iVar6" (identifier "iVar3") (= "=") (identifier "iVar6")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(*piVar1 != 0)" (( "(") (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (!= "!=") (number_literal "0")) () ")")) (; ";")) (} "}")) (else_clause "else {\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" (else "else") (compound_statement "{\n      do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);\n    }" ({ "{") (do_statement "do {\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      } while (*piVar1 != 0);" (do "do") (compound_statement "{\n        piVar1 = (int *)(puVar5 + 4);\n        iVar6 = iVar6 + 1;\n        puVar5 = puVar5 + 8;\n        iVar3 = iVar6;\n      }" ({ "{") (expression_statement "piVar1 = (int *)(puVar5 + 4);" (assignment_expression "piVar1 = (int *)(puVar5 + 4)" (identifier "piVar1") (= "=") (cast_expression "(int *)(puVar5 + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar5 + 4)" (( "(") (binary_expression "puVar5 + 4" (identifier "puVar5") (+ "+") (number_literal "4")) () ")")))) (; ";")) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" (identifier "iVar6") (= "=") (binary_expression "iVar6 + 1" (identifier "iVar6") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "puVar5 = puVar5 + 8;" (assignment_expression "puVar5 = puVar5 + 8" (identifier "puVar5") (= "=") (binary_expression "puVar5 + 8" (identifier "puVar5") (+ "+") (number_literal "8"))) (; ";")) (expression_statement "iVar3 = iVar6;" (assignment_expression "iVar3 = iVar6" (identifier "iVar3") (= "=") (identifier "iVar6")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(*piVar1 != 0)" (( "(") (binary_expression "*piVar1 != 0" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (!= "!=") (number_literal "0")) () ")")) (; ";")) (} "}")))) (} "}")))) (expression_statement "puVar2[9] = iVar3;" (assignment_expression "puVar2[9] = iVar3" (subscript_expression "puVar2[9]" (identifier "puVar2") ([ "[") (number_literal "9") (] "]")) (= "=") (identifier "iVar3")) (; ";")) (if_statement "if (param_3 == '\0') {\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }\n  else {\n    puVar2[0xb] = 0;\n  }" (if "if") (parenthesized_expression "(param_3 == '\0')" (( "(") (binary_expression "param_3 == '\0'" (identifier "param_3") (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n    uVar4 = FUN_000313e0(iVar3,1);\n    puVar2[0xb] = uVar4;\n    iVar3 = puVar2[9];\n  }" ({ "{") (expression_statement "uVar4 = FUN_000313e0(iVar3,1);" (assignment_expression "uVar4 = FUN_000313e0(iVar3,1)" (identifier "uVar4") (= "=") (call_expression "FUN_000313e0(iVar3,1)" (identifier "FUN_000313e0") (argument_list "(iVar3,1)" (( "(") (identifier "iVar3") (, ",") (number_literal "1") () ")")))) (; ";")) (expression_statement "puVar2[0xb] = uVar4;" (assignment_expression "puVar2[0xb] = uVar4" (subscript_expression "puVar2[0xb]" (identifier "puVar2") ([ "[") (number_literal "0xb") (] "]")) (= "=") (identifier "uVar4")) (; ";")) (expression_statement "iVar3 = puVar2[9];" (assignment_expression "iVar3 = puVar2[9]" (identifier "iVar3") (= "=") (subscript_expression "puVar2[9]" (identifier "puVar2") ([ "[") (number_literal "9") (] "]"))) (; ";")) (} "}")) (else_clause "else {\n    puVar2[0xb] = 0;\n  }" (else "else") (compound_statement "{\n    puVar2[0xb] = 0;\n  }" ({ "{") (expression_statement "puVar2[0xb] = 0;" (assignment_expression "puVar2[0xb] = 0" (subscript_expression "puVar2[0xb]" (identifier "puVar2") ([ "[") (number_literal "0xb") (] "]")) (= "=") (number_literal "0")) (; ";")) (} "}")))) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" (identifier "iVar6") (= "=") (number_literal "0")) (; ";")) (expression_statement "uVar4 = FUN_000313e0(iVar3,4);" (assignment_expression "uVar4 = FUN_000313e0(iVar3,4)" (identifier "uVar4") (= "=") (call_expression "FUN_000313e0(iVar3,4)" (identifier "FUN_000313e0") (argument_list "(iVar3,4)" (( "(") (identifier "iVar3") (, ",") (number_literal "4") () ")")))) (; ";")) (expression_statement "puVar2[10] = uVar4;" (assignment_expression "puVar2[10] = uVar4" (subscript_expression "puVar2[10]" (identifier "puVar2") ([ "[") (number_literal "10") (] "]")) (= "=") (identifier "uVar4")) (; ";")) (expression_statement "uVar4 = FUN_000313e0(puVar2[9],4);" (assignment_expression "uVar4 = FUN_000313e0(puVar2[9],4)" (identifier "uVar4") (= "=") (call_expression "FUN_000313e0(puVar2[9],4)" (identifier "FUN_000313e0") (argument_list "(puVar2[9],4)" (( "(") (subscript_expression "puVar2[9]" (identifier "puVar2") ([ "[") (number_literal "9") (] "]")) (, ",") (number_literal "4") () ")")))) (; ";")) (expression_statement "puVar2[0xc] = uVar4;" (assignment_expression "puVar2[0xc] = uVar4" (subscript_expression "puVar2[0xc]" (identifier "puVar2") ([ "[") (number_literal "0xc") (] "]")) (= "=") (identifier "uVar4")) (; ";")) (expression_statement "puVar7 = &param_8;" (assignment_expression "puVar7 = &param_8" (identifier "puVar7") (= "=") (pointer_expression "&param_8" (& "&") (identifier "param_8"))) (; ";")) (if_statement "if (0 < (int)puVar2[9]) {\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }" (if "if") (parenthesized_expression "(0 < (int)puVar2[9])" (( "(") (binary_expression "0 < (int)puVar2[9]" (number_literal "0") (< "<") (cast_expression "(int)puVar2[9]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "puVar2[9]" (identifier "puVar2") ([ "[") (number_literal "9") (] "]")))) () ")")) (compound_statement "{\n    do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);\n  }" ({ "{") (do_statement "do {\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    } while (iVar6 < (int)puVar2[9]);" (do "do") (compound_statement "{\n      while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }\n      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];\n      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];\n      iVar6 = iVar6 + 1;\n      puVar7 = puVar7 + 3;\n    }" ({ "{") (while_statement "while( true ) {\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n        iVar3 = puVar2[10];\n        uVar4 = FUN_00030420(*puVar7);\n        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;\n        if (*(char *)(puVar2 + 7) == '\0') break;\n        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];\n        iVar6 = iVar6 + 1;\n        puVar7 = puVar7 + 2;\n        if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }\n      }" ({ "{") (expression_statement "iVar3 = puVar2[10];" (assignment_expression "iVar3 = puVar2[10]" (identifier "iVar3") (= "=") (subscript_expression "puVar2[10]" (identifier "puVar2") ([ "[") (number_literal "10") (] "]"))) (; ";")) (expression_statement "uVar4 = FUN_00030420(*puVar7);" (assignment_expression "uVar4 = FUN_00030420(*puVar7)" (identifier "uVar4") (= "=") (call_expression "FUN_00030420(*puVar7)" (identifier "FUN_00030420") (argument_list "(*puVar7)" (( "(") (pointer_expression "*puVar7" (* "*") (identifier "puVar7")) () ")")))) (; ";")) (expression_statement "*(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;" (assignment_expression "*(undefined4 *)(iVar3 + iVar6 * 4) = uVar4" (pointer_expression "*(undefined4 *)(iVar3 + iVar6 * 4)" (* "*") (cast_expression "(undefined4 *)(iVar3 + iVar6 * 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar3 + iVar6 * 4)" (( "(") (binary_expression "iVar3 + iVar6 * 4" (identifier "iVar3") (+ "+") (binary_expression "iVar6 * 4" (identifier "iVar6") (* "*") (number_literal "4"))) () ")")))) (= "=") (identifier "uVar4")) (; ";")) (if_statement "if (*(char *)(puVar2 + 7) == '\0') break;" (if "if") (parenthesized_expression "(*(char *)(puVar2 + 7) == '\0')" (( "(") (binary_expression "*(char *)(puVar2 + 7) == '\0'" (pointer_expression "*(char *)(puVar2 + 7)" (* "*") (cast_expression "(char *)(puVar2 + 7)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar2 + 7)" (( "(") (binary_expression "puVar2 + 7" (identifier "puVar2") (+ "+") (number_literal "7")) () ")")))) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];" (assignment_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1]" (pointer_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4)" (* "*") (cast_expression "(undefined4 *)(puVar2[0xc] + iVar6 * 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar2[0xc] + iVar6 * 4)" (( "(") (binary_expression "puVar2[0xc] + iVar6 * 4" (subscript_expression "puVar2[0xc]" (identifier "puVar2") ([ "[") (number_literal "0xc") (] "]")) (+ "+") (binary_expression "iVar6 * 4" (identifier "iVar6") (* "*") (number_literal "4"))) () ")")))) (= "=") (subscript_expression "puVar7[1]" (identifier "puVar7") ([ "[") (number_literal "1") (] "]"))) (; ";")) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" (identifier "iVar6") (= "=") (binary_expression "iVar6 + 1" (identifier "iVar6") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "puVar7 = puVar7 + 2;" (assignment_expression "puVar7 = puVar7 + 2" (identifier "puVar7") (= "=") (binary_expression "puVar7 + 2" (identifier "puVar7") (+ "+") (number_literal "2"))) (; ";")) (if_statement "if ((int)puVar2[9] <= iVar6) {\n          return puVar2;\n        }" (if "if") (parenthesized_expression "((int)puVar2[9] <= iVar6)" (( "(") (binary_expression "(int)puVar2[9] <= iVar6" (cast_expression "(int)puVar2[9]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "puVar2[9]" (identifier "puVar2") ([ "[") (number_literal "9") (] "]"))) (<= "<=") (identifier "iVar6")) () ")")) (compound_statement "{\n          return puVar2;\n        }" ({ "{") (return_statement "return puVar2;" (return "return") (identifier "puVar2") (; ";")) (} "}"))) (} "}"))) (expression_statement "*(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];" (assignment_expression "*(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1]" (pointer_expression "*(char *)(puVar2[0xb] + iVar6)" (* "*") (cast_expression "(char *)(puVar2[0xb] + iVar6)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar2[0xb] + iVar6)" (( "(") (binary_expression "puVar2[0xb] + iVar6" (subscript_expression "puVar2[0xb]" (identifier "puVar2") ([ "[") (number_literal "0xb") (] "]")) (+ "+") (identifier "iVar6")) () ")")))) (= "=") (cast_expression "(char)puVar7[1]" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (subscript_expression "puVar7[1]" (identifier "puVar7") ([ "[") (number_literal "1") (] "]")))) (; ";")) (expression_statement "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];" (assignment_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2]" (pointer_expression "*(undefined4 *)(puVar2[0xc] + iVar6 * 4)" (* "*") (cast_expression "(undefined4 *)(puVar2[0xc] + iVar6 * 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar2[0xc] + iVar6 * 4)" (( "(") (binary_expression "puVar2[0xc] + iVar6 * 4" (subscript_expression "puVar2[0xc]" (identifier "puVar2") ([ "[") (number_literal "0xc") (] "]")) (+ "+") (binary_expression "iVar6 * 4" (identifier "iVar6") (* "*") (number_literal "4"))) () ")")))) (= "=") (subscript_expression "puVar7[2]" (identifier "puVar7") ([ "[") (number_literal "2") (] "]"))) (; ";")) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" (identifier "iVar6") (= "=") (binary_expression "iVar6 + 1" (identifier "iVar6") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "puVar7 = puVar7 + 3;" (assignment_expression "puVar7 = puVar7 + 3" (identifier "puVar7") (= "=") (binary_expression "puVar7 + 3" (identifier "puVar7") (+ "+") (number_literal "3"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar6 < (int)puVar2[9])" (( "(") (binary_expression "iVar6 < (int)puVar2[9]" (identifier "iVar6") (< "<") (cast_expression "(int)puVar2[9]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "puVar2[9]" (identifier "puVar2") ([ "[") (number_literal "9") (] "]")))) () ")")) (; ";")) (} "}"))) (return_statement "return puVar2;" (return "return") (identifier "puVar2") (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

type_1 * function_1(type_2 *s,char *var_4,char var_7,int ncolumns,type_3 helpctx,
                           type_4 handler,type_3 context,...)

{
  int *piVar1;
  type_1 *pcVar2;
  size_t n;
  char **ppcVar3;
  type_3 *piVar4;
  char *pcVar5;
  type_5 *var_9;
  type_1 **ppcVar7;
  size_t var_8;
  type_6 *var_10;
  int var_2;
  int var_6;
  
  pcVar2 = (type_1 *)var_1(1,0x3c);
  var_2 = s->ncontrols;
  if (var_2 < s->ctrlsize) {
    ppcVar7 = s->ctrls;
  }
  else {
    s->ctrlsize = var_2 + 0x20U;
    ppcVar7 = (type_1 **)var_3(s->ctrls,var_2 + 0x20U,4);
    var_2 = s->ncontrols;
    s->ctrls = ppcVar7;
  }
  s->ncontrols = var_2 + 1;
  ppcVar7[var_2] = pcVar2;
  var_2 = s->ncolumns;
  (pcVar2->generic).type = 2;
  (pcVar2->generic).tabdelay = 0;
  (pcVar2->generic).var_4 = (char *)0x0;
  (pcVar2->generic).column = (var_2 + -1) * 0x10000;
  (pcVar2->generic).helpctx = helpctx;
  (pcVar2->generic).handler = handler;
  (pcVar2->generic).context = context;
  if (var_4 != (char *)0x0) {
    var_4 = var_5(var_4);
  }
  (pcVar2->generic).var_4 = var_4;
  (pcVar2->editbox).var_7 = var_7;
  (pcVar2->editbox).percentwidth = ncolumns;
  var_9 = &stack0x00000024;
  if (var_6 == 0) {
    n = 0;
  }
  else {
    var_8 = 0;
    if (var_7 == '\0') {
      do {
        n = var_8 + 1;
        if (*(int *)(var_9 + 8) == 0) break;
        piVar1 = (int *)(var_9 + 0x14);
        var_8 = var_8 + 2;
        var_9 = var_9 + 0x18;
        n = var_8;
      } while (*piVar1 != 0);
    }
    else {
      do {
        piVar1 = (int *)(var_9 + 4);
        var_8 = var_8 + 1;
        var_9 = var_9 + 8;
        n = var_8;
      } while (*piVar1 != 0);
    }
  }
  (pcVar2->editbox).password = n;
  if (var_7 == '\0') {
    pcVar5 = (char *)var_1(n,1);
    (pcVar2->radio).shortcuts = pcVar5;
    n = (pcVar2->editbox).password;
  }
  else {
    (pcVar2->radio).shortcuts = (char *)0x0;
  }
  var_2 = 0;
  ppcVar3 = (char **)var_1(n,4);
  (pcVar2->radio).buttons = ppcVar3;
  piVar4 = (type_3 *)var_1((pcVar2->editbox).password,4);
  (pcVar2->radio).buttondata = piVar4;
  var_10 = &stack0x00000020;
  if (0 < (pcVar2->editbox).password) {
    do {
      while( true ) {
        ppcVar3 = (pcVar2->radio).buttons;
        pcVar5 = var_5((char *)*var_10);
        ppcVar3[var_2] = pcVar5;
        if ((pcVar2->editbox).var_7 == '\0') break;
        (pcVar2->radio).buttondata[var_2] = *(type_3 *)(var_10 + 1);
        var_2 = var_2 + 1;
        var_10 = var_10 + 2;
        if ((pcVar2->editbox).password <= var_2) {
          return pcVar2;
        }
      }
      (pcVar2->radio).shortcuts[var_2] = (char)var_10[1];
      (pcVar2->radio).buttondata[var_2] = *(type_3 *)(var_10 + 2);
      var_2 = var_2 + 1;
      var_10 = var_10 + 3;
    } while (var_2 < (pcVar2->editbox).password);
  }
  return pcVar2;
}


(translation_unit (function_definition type: (type_identifier) declarator: (pointer_declarator declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (number_literal) (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) (binary_expression left: (identifier) right: (number_literal)) (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))))) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))) consequence: (compound_statement (do_statement body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))))) alternative: (else_clause (compound_statement (do_statement body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal)))))))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (subscript_expression argument: (identifier) index: (number_literal)) (number_literal))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (number_literal) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))))) consequence: (compound_statement (do_statement body: (compound_statement (while_statement condition: (parenthesized_expression (true)) body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))))) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (char_literal (escape_sequence)))) consequence: (break_statement)) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))))) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))) right: (identifier))) consequence: (compound_statement (return_statement (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))))) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal)))))))) (return_statement (identifier)))))

/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

undefined4 *
MASKED(int param_1,int param_2,char param_3,undefined4 param_4,undefined4 param_5,
            undefined4 param_6,undefined4 param_7,int param_8)

{
  int *piVar1;
  undefined4 *puVar2;
  int iVar3;
  undefined4 uVar4;
  undefined1 *puVar5;
  int iVar6;
  undefined4 *puVar7;
  
  puVar2 = (undefined4 *)FUN_000313e0(1,0x3c);
  iVar3 = *(int *)(param_1 + 0x10);
  if (iVar3 < *(int *)(param_1 + 0x14)) {
    iVar6 = *(int *)(param_1 + 0x18);
  }
  else {
    *(int *)(param_1 + 0x14) = iVar3 + 0x20;
    iVar6 = FUN_000314a0(*(undefined4 *)(param_1 + 0x18),iVar3 + 0x20,4);
    iVar3 = *(int *)(param_1 + 0x10);
    *(int *)(param_1 + 0x18) = iVar6;
  }
  *(int *)(param_1 + 0x10) = iVar3 + 1;
  *(undefined4 **)(iVar6 + iVar3 * 4) = puVar2;
  iVar3 = *(int *)(param_1 + 0xc);
  *puVar2 = 2;
  puVar2[2] = 0;
  puVar2[1] = 0;
  puVar2[3] = (iVar3 + -1) * 0x10000;
  puVar2[6] = param_5;
  puVar2[4] = param_6;
  puVar2[5] = param_7;
  if (param_2 != 0) {
    param_2 = FUN_00030420(param_2);
  }
  puVar2[1] = param_2;
  *(char *)(puVar2 + 7) = param_3;
  puVar2[8] = param_4;
  puVar5 = &stack0x00000024;
  if (param_8 == 0) {
    iVar3 = 0;
  }
  else {
    iVar6 = 0;
    if (param_3 == '\0') {
      do {
        iVar3 = iVar6 + 1;
        if (*(int *)(puVar5 + 8) == 0) break;
        piVar1 = (int *)(puVar5 + 0x14);
        iVar6 = iVar6 + 2;
        puVar5 = puVar5 + 0x18;
        iVar3 = iVar6;
      } while (*piVar1 != 0);
    }
    else {
      do {
        piVar1 = (int *)(puVar5 + 4);
        iVar6 = iVar6 + 1;
        puVar5 = puVar5 + 8;
        iVar3 = iVar6;
      } while (*piVar1 != 0);
    }
  }
  puVar2[9] = iVar3;
  if (param_3 == '\0') {
    uVar4 = FUN_000313e0(iVar3,1);
    puVar2[0xb] = uVar4;
    iVar3 = puVar2[9];
  }
  else {
    puVar2[0xb] = 0;
  }
  iVar6 = 0;
  uVar4 = FUN_000313e0(iVar3,4);
  puVar2[10] = uVar4;
  uVar4 = FUN_000313e0(puVar2[9],4);
  puVar2[0xc] = uVar4;
  puVar7 = &param_8;
  if (0 < (int)puVar2[9]) {
    do {
      while( true ) {
        iVar3 = puVar2[10];
        uVar4 = FUN_00030420(*puVar7);
        *(undefined4 *)(iVar3 + iVar6 * 4) = uVar4;
        if (*(char *)(puVar2 + 7) == '\0') break;
        *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[1];
        iVar6 = iVar6 + 1;
        puVar7 = puVar7 + 2;
        if ((int)puVar2[9] <= iVar6) {
          return puVar2;
        }
      }
      *(char *)(puVar2[0xb] + iVar6) = (char)puVar7[1];
      *(undefined4 *)(puVar2[0xc] + iVar6 * 4) = puVar7[2];
      iVar6 = iVar6 + 1;
      puVar7 = puVar7 + 3;
    } while (iVar6 < (int)puVar2[9]);
  }
  return puVar2;
}

