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

int __regparm3 sqlite3VdbeMemSetStr(Mem *pMem,char *z,int n,u8 enc,_func_void_void_ptr *xDel)

{
  char cVar1;
  char cVar2;
  ushort uVar3;
  int iVar4;
  char *__dest;
  size_t sVar5;
  int iVar6;
  size_t szNew;
  u8 uVar7;
  ushort local_28;
  size_t local_24;
  
  if (z == (char *)0x0) {
    if ((pMem->flags & 0x2400) != 0) {
      vdbeMemClearExternAndSetNull(pMem);
      return 0;
    }
    pMem->flags = 1;
    return 0;
  }
  iVar6 = 1000000000;
  if (pMem->db != (sqlite3 *)0x0) {
    iVar6 = pMem->db->aLimit[0];
  }
  sVar5 = n;
  local_24 = n;
  if (enc == '\0') {
    if (n < 0) {
      local_28 = 0x210;
LAB_0004554a:
      if (iVar6 < 0) {
        n = 0;
      }
      else {
        n = 0;
        sVar5 = n;
        if (*z != '\0' || z[1] != '\0') {
          do {
            n = sVar5 + 2;
            if (iVar6 < n) break;
            iVar4 = sVar5 + 3;
            sVar5 = n;
          } while (z[n] != '\0' || z[iVar4] != '\0');
        }
      }
      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {
        iVar4 = 2;
        goto LAB_00045582;
      }
    }
    else {
      local_28 = 0x10;
      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;
    }
LAB_000453ae:
    uVar3 = pMem->flags & 0x2400;
    if (xDel == sqlite3MallocSize) {
      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {
        vdbeMemClear(pMem);
      }
      pMem->z = z;
      pMem->zMalloc = z;
      iVar4 = (*sqlite3Config.m.xSize)(z);
      pMem->szMalloc = iVar4;
    }
    else {
      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {
        vdbeMemClear(pMem);
      }
      pMem->z = z;
      pMem->xDel = xDel;
      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;
    }
  }
  else {
    local_28 = 2;
    if (n < 0) {
      if (enc != '\x01') {
        local_28 = 0x202;
        goto LAB_0004554a;
      }
      n = strlen(z);
      if (iVar6 < n) {
        n = iVar6 + 1;
      }
      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {
        local_28 = 0x202;
        goto LAB_000453ae;
      }
      local_28 = 0x202;
      iVar4 = 1;
LAB_00045582:
      sVar5 = n + iVar4;
      local_24 = n;
    }
    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;
LAB_00045588:
    if (iVar6 < (int)local_24) {
      return 0x12;
    }
    szNew = 0x20;
    if (0x1f < (int)sVar5) {
      szNew = sVar5;
    }
    if (pMem->szMalloc < (int)szNew) {
      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);
      if (iVar4 != 0) {
        return 7;
      }
      __dest = pMem->z;
    }
    else {
      __dest = pMem->zMalloc;
      pMem->flags = pMem->flags & 0xd;
      pMem->z = __dest;
    }
    memcpy(__dest,z,sVar5);
    n = local_24;
  }
  pMem->n = n;
  pMem->flags = local_28;
  if (enc == '\0') {
    pMem->enc = '\x01';
  }
  else {
    pMem->enc = enc;
    if ((1 < n) && (enc != '\x01')) {
      cVar1 = *pMem->z;
      cVar2 = pMem->z[1];
      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {
        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;
        uVar7 = '\x02';
      }
      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);
      if (iVar4 != 0) {
        return 7;
      }
      sVar5 = pMem->n - 2;
      pMem->n = sVar5;
      memmove(pMem->z,pMem->z + 2,sVar5);
      pMem->z[pMem->n] = '\0';
      pMem->z[pMem->n + 1] = '\0';
      pMem->flags = pMem->flags | 0x200;
      pMem->enc = uVar7;
    }
  }
LAB_00045408:
  if (iVar6 < n) {
    return 0x12;
  }
  return 0;
}



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

undefined4 __regparm3
FUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)

{
  char cVar1;
  char cVar2;
  ushort uVar3;
  int iVar4;
  undefined4 uVar5;
  void *__dest;
  size_t sVar6;
  int iVar7;
  size_t sVar8;
  undefined1 uVar9;
  ushort local_28;
  size_t local_24;
  
  if (param_2 == (char *)0x0) {
    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {
      FUN_00024f00();
      return 0;
    }
    *(undefined2 *)(param_1 + 8) = 1;
    return 0;
  }
  iVar7 = 1000000000;
  if (*(int *)(param_1 + 0x20) != 0) {
    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);
  }
  sVar6 = param_3;
  local_24 = param_3;
  if (param_4 == '\0') {
    if ((int)param_3 < 0) {
      local_28 = 0x210;
LAB_0004554a:
      if (iVar7 < 0) {
        param_3 = 0;
      }
      else {
        param_3 = 0;
        sVar6 = param_3;
        if (*param_2 != '\0' || param_2[1] != '\0') {
          do {
            param_3 = sVar6 + 2;
            if (iVar7 < (int)param_3) break;
            iVar4 = sVar6 + 3;
            sVar6 = param_3;
          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');
        }
      }
      if (param_5 == (code *)0xffffffff) {
        iVar4 = 2;
        goto LAB_00045582;
      }
    }
    else {
      local_28 = 0x10;
      if (param_5 == (code *)0xffffffff) goto LAB_00045588;
    }
LAB_000453ae:
    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;
    if (param_5 == FUN_00019850) {
      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {
        FUN_00025180();
      }
      *(char **)(param_1 + 0x10) = param_2;
      *(char **)(param_1 + 0x14) = param_2;
      uVar5 = (*DAT_001491b8)(param_2);
      *(undefined4 *)(param_1 + 0x18) = uVar5;
    }
    else {
      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {
        FUN_00025180();
      }
      *(char **)(param_1 + 0x10) = param_2;
      *(code **)(param_1 + 0x24) = param_5;
      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;
    }
  }
  else {
    local_28 = 2;
    if ((int)param_3 < 0) {
      if (param_4 != '\x01') {
        local_28 = 0x202;
        goto LAB_0004554a;
      }
      param_3 = strlen(param_2);
      if (iVar7 < (int)param_3) {
        param_3 = iVar7 + 1;
      }
      if (param_5 != (code *)0xffffffff) {
        local_28 = 0x202;
        goto LAB_000453ae;
      }
      local_28 = 0x202;
      iVar4 = 1;
LAB_00045582:
      sVar6 = param_3 + iVar4;
      local_24 = param_3;
    }
    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;
LAB_00045588:
    if (iVar7 < (int)local_24) {
      return 0x12;
    }
    sVar8 = 0x20;
    if (0x1f < (int)sVar6) {
      sVar8 = sVar6;
    }
    if (*(int *)(param_1 + 0x18) < (int)sVar8) {
      iVar4 = FUN_00044790();
      if (iVar4 != 0) {
        return 7;
      }
      __dest = *(void **)(param_1 + 0x10);
    }
    else {
      __dest = *(void **)(param_1 + 0x14);
      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;
      *(void **)(param_1 + 0x10) = __dest;
    }
    memcpy(__dest,param_2,sVar6);
    param_3 = local_24;
  }
  *(size_t *)(param_1 + 0xc) = param_3;
  *(ushort *)(param_1 + 8) = local_28;
  if (param_4 == '\0') {
    *(undefined1 *)(param_1 + 10) = 1;
  }
  else {
    *(char *)(param_1 + 10) = param_4;
    if ((1 < (int)param_3) && (param_4 != '\x01')) {
      cVar1 = **(char **)(param_1 + 0x10);
      cVar2 = (*(char **)(param_1 + 0x10))[1];
      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {
        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;
        uVar9 = 2;
      }
      iVar4 = FUN_000452f0();
      if (iVar4 != 0) {
        return 7;
      }
      sVar6 = *(int *)(param_1 + 0xc) - 2;
      *(size_t *)(param_1 + 0xc) = sVar6;
      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);
      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;
      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;
      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;
      *(undefined1 *)(param_1 + 10) = uVar9;
    }
  }
LAB_00045408:
  if (iVar7 < (int)param_3) {
    return 0x12;
  }
  return 0;
}


PUSH EBP
PUSH EDI
MOV EDI,EAX
PUSH ESI
PUSH EBX
CALL 0x00014cf0
ADD EBX,0x103b79
SUB ESP,0x1c
MOV EAX,dword ptr [ESP + 0x30]
MOV dword ptr [ESP],EAX
TEST EDX,EDX
JZ 0x000454e0
MOV EAX,dword ptr [EDI + 0x20]
MOV ESI,ECX
MOV EBP,EDX
MOV ECX,0x3b9aca00
TEST EAX,EAX
JZ 0x00045386
MOV ECX,dword ptr [EAX + 0x68]
MOV EAX,dword ptr [ESP]
TEST AL,AL
JZ 0x00045420
MOV EDX,0x2
MOV word ptr [ESP + 0x4],DX
TEST ESI,ESI
JS 0x000455d0
CMP dword ptr [ESP + 0x34],-0x1
JZ 0x0004543d
MOVZX EAX,word ptr [EDI + 0x8]
LEA EDX,[EBX + 0xffed097c]
AND AX,0x2400
CMP dword ptr [ESP + 0x34],EDX
JZ 0x00045500
TEST AX,AX
JNZ 0x00045450
MOV EAX,dword ptr [EDI + 0x18]
TEST EAX,EAX
JNZ 0x00045450
MOV EAX,dword ptr [ESP + 0x34]
MOV dword ptr [EDI + 0x10],EBP
CMP EAX,0x1
MOV dword ptr [EDI + 0x24],EAX
SBB EAX,EAX
AND AX,0x400
ADD AX,0x400
OR word ptr [ESP + 0x4],AX
MOVZX EAX,word ptr [ESP + 0x4]
CMP byte ptr [ESP],0x0
MOV dword ptr [EDI + 0xc],ESI
MOV word ptr [EDI + 0x8],AX
JNZ 0x00045468
MOV byte ptr [EDI + 0xa],0x1
XOR EAX,EAX
CMP ECX,ESI
JL 0x000454b0
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
TEST ESI,ESI
JS 0x00045540
MOV EAX,0x10
CMP dword ptr [ESP + 0x34],-0x1
MOV word ptr [ESP + 0x4],AX
JNZ 0x000453ae
MOV dword ptr [ESP + 0x8],ESI
JMP 0x00045588
MOV EAX,EDI
MOV dword ptr [ESP + 0x8],ECX
CALL 0x00025180
MOV ECX,dword ptr [ESP + 0x8]
JMP 0x000453d6
MOV EDX,dword ptr [ESP]
MOV byte ptr [EDI + 0xa],DL
CMP ESI,0x1
JLE 0x00045408
CMP DL,0x1
JZ 0x00045408
MOV EAX,dword ptr [EDI + 0x10]
MOVZX EDX,byte ptr [EAX]
MOVZX EAX,byte ptr [EAX + 0x1]
CMP DL,0xfe
JNZ 0x000454c0
MOV EBP,0x3
CMP AL,0xff
JNZ 0x000454c0
MOV EAX,EDI
MOV dword ptr [ESP],ECX
CALL 0x000452f0
TEST EAX,EAX
JZ 0x00045630
ADD ESP,0x1c
MOV EAX,0x7
POP EBX
POP ESI
POP EDI
POP EBP
RET
ADD ESP,0x1c
MOV EAX,0x12
POP EBX
POP ESI
POP EDI
POP EBP
RET
CMP DL,0xff
JNZ 0x00045408
CMP AL,0xfe
JNZ 0x00045408
MOV EBP,0x2
JMP 0x00045490
TEST word ptr [EDI + 0x8],0x2400
JNZ 0x00045610
MOV ECX,0x1
XOR EAX,EAX
MOV word ptr [EDI + 0x8],CX
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
TEST AX,AX
JNZ 0x0004550c
MOV EAX,dword ptr [EDI + 0x18]
TEST EAX,EAX
JZ 0x0004551b
MOV EAX,EDI
MOV dword ptr [ESP + 0x8],ECX
CALL 0x00025180
MOV ECX,dword ptr [ESP + 0x8]
MOV dword ptr [ESP + 0x8],ECX
SUB ESP,0xc
PUSH EBP
MOV dword ptr [EDI + 0x10],EBP
MOV dword ptr [EDI + 0x14],EBP
CALL dword ptr [EBX + 0x2e4]
ADD ESP,0x10
MOV ECX,dword ptr [ESP + 0x8]
MOV dword ptr [EDI + 0x18],EAX
JMP 0x000453f2
MOV EAX,0x210
MOV word ptr [ESP + 0x4],AX
TEST ECX,ECX
JS 0x000456af
MOVZX EAX,byte ptr [EBP]
XOR ESI,ESI
OR AL,byte ptr [EBP + 0x1]
JNZ 0x0004556b
JMP 0x00045572
MOVZX EAX,byte ptr [EBP + ESI*0x1]
OR AL,byte ptr [EBP + ESI*0x1 + 0x1]
JZ 0x00045572
ADD ESI,0x2
CMP ECX,ESI
JGE 0x00045560
CMP dword ptr [ESP + 0x34],-0x1
JNZ 0x000453ae
MOV EAX,0x2
MOV dword ptr [ESP + 0x8],ESI
ADD ESI,EAX
CMP ECX,dword ptr [ESP + 0x8]
JL 0x000454b0
CMP ESI,0x20
MOV EDX,0x20
CMOVGE EDX,ESI
CMP EDX,dword ptr [EDI + 0x18]
JG 0x00045690
MOV EAX,dword ptr [EDI + 0x14]
AND word ptr [EDI + 0x8],0xd
MOV dword ptr [EDI + 0x10],EAX
MOV dword ptr [ESP + 0xc],ECX
SUB ESP,0x4
PUSH ESI
PUSH EBP
PUSH EAX
CALL 0x000140d0
ADD ESP,0x10
MOV ESI,dword ptr [ESP + 0x8]
MOV ECX,dword ptr [ESP + 0xc]
JMP 0x000453f2
CMP AL,0x1
JNZ 0x00045620
MOV dword ptr [ESP + 0x4],ECX
SUB ESP,0xc
PUSH EBP
CALL 0x00014230
ADD ESP,0x10
MOV ECX,dword ptr [ESP + 0x4]
MOV ESI,EAX
CMP ESI,ECX
LEA EAX,[ECX + 0x1]
CMOVG ESI,EAX
CMP dword ptr [ESP + 0x34],-0x1
JZ 0x00045678
MOV EDX,0x202
MOV word ptr [ESP + 0x4],DX
JMP 0x000453ae
MOV EAX,EDI
CALL 0x00024f00
XOR EAX,EAX
JMP 0x00045412
MOV EAX,0x202
MOV word ptr [ESP + 0x4],AX
JMP 0x0004554a
MOV EAX,dword ptr [EDI + 0xc]
MOV EDX,dword ptr [EDI + 0x10]
SUB ESP,0x4
SUB EAX,0x2
PUSH EAX
MOV dword ptr [EDI + 0xc],EAX
LEA EAX,[EDX + 0x2]
PUSH EAX
PUSH EDX
CALL 0x000140b0
MOV EDX,dword ptr [EDI + 0x10]
MOV EAX,dword ptr [EDI + 0xc]
ADD ESP,0x10
MOV ECX,dword ptr [ESP]
MOV byte ptr [EDX + EAX*0x1],0x0
MOV EAX,dword ptr [EDI + 0xc]
MOV EDX,dword ptr [EDI + 0x10]
MOV byte ptr [EDX + EAX*0x1 + 0x1],0x0
MOV EAX,EBP
OR word ptr [EDI + 0x8],0x200
MOV byte ptr [EDI + 0xa],AL
JMP 0x00045408
MOV EAX,0x202
MOV word ptr [ESP + 0x4],AX
MOV EAX,0x1
JMP 0x00045582
MOV EAX,EDI
MOV dword ptr [ESP + 0xc],ECX
CALL 0x00044790
MOV ECX,dword ptr [ESP + 0xc]
TEST EAX,EAX
JNZ 0x000454a2
MOV EAX,dword ptr [EDI + 0x10]
JMP 0x000455b1
XOR ESI,ESI
JMP 0x00045572
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 __regparm3\nFUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}\n\n" comment (function_definition "undefined4 __regparm3\nFUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)" identifier (parameter_list "(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "size_t param_3" primitive_type identifier) , (parameter_declaration "char param_4" primitive_type identifier) , (parameter_declaration "code *param_5" type_identifier (pointer_declarator "*param_5" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "char cVar2;" primitive_type identifier ;) (declaration "ushort uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "undefined4 uVar5;" type_identifier identifier ;) (declaration "void *__dest;" primitive_type (pointer_declarator "*__dest" * identifier) ;) (declaration "size_t sVar6;" primitive_type identifier ;) (declaration "int iVar7;" primitive_type identifier ;) (declaration "size_t sVar8;" primitive_type identifier ;) (declaration "undefined1 uVar9;" type_identifier identifier ;) (declaration "ushort local_28;" type_identifier identifier ;) (declaration "size_t local_24;" primitive_type identifier ;) (if_statement "if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }" if (parenthesized_expression "(param_2 == (char *)0x0)" ( (binary_expression "param_2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }" { (if_statement "if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }" if (parenthesized_expression "((*(ushort *)(param_1 + 8) & 0x2400) != 0)" ( (binary_expression "(*(ushort *)(param_1 + 8) & 0x2400) != 0" (parenthesized_expression "(*(ushort *)(param_1 + 8) & 0x2400)" ( (binary_expression "*(ushort *)(param_1 + 8) & 0x2400" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n      FUN_00024f00();\n      return 0;\n    }" { (expression_statement "FUN_00024f00();" (call_expression "FUN_00024f00()" identifier (argument_list "()" ( ))) ;) (return_statement "return 0;" return number_literal ;) })) (expression_statement "*(undefined2 *)(param_1 + 8) = 1;" (assignment_expression "*(undefined2 *)(param_1 + 8) = 1" (pointer_expression "*(undefined2 *)(param_1 + 8)" * (cast_expression "(undefined2 *)(param_1 + 8)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = number_literal) ;) (return_statement "return 0;" return number_literal ;) })) (expression_statement "iVar7 = 1000000000;" (assignment_expression "iVar7 = 1000000000" identifier = number_literal) ;) (if_statement "if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x20) != 0)" ( (binary_expression "*(int *)(param_1 + 0x20) != 0" (pointer_expression "*(int *)(param_1 + 0x20)" * (cast_expression "(int *)(param_1 + 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x20)" ( (binary_expression "param_1 + 0x20" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }" { (expression_statement "iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);" (assignment_expression "iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68)" identifier = (pointer_expression "*(int *)(*(int *)(param_1 + 0x20) + 0x68)" * (cast_expression "(int *)(*(int *)(param_1 + 0x20) + 0x68)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(param_1 + 0x20) + 0x68)" ( (binary_expression "*(int *)(param_1 + 0x20) + 0x68" (pointer_expression "*(int *)(param_1 + 0x20)" * (cast_expression "(int *)(param_1 + 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x20)" ( (binary_expression "param_1 + 0x20" identifier + number_literal) )))) + number_literal) ))))) ;) })) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" identifier = identifier) ;) (expression_statement "local_24 = param_3;" (assignment_expression "local_24 = param_3" identifier = identifier) ;) (if_statement "if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" if (parenthesized_expression "(param_4 == '\0')" ( (binary_expression "param_4 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }" { (if_statement "if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" if (parenthesized_expression "((int)param_3 < 0)" ( (binary_expression "(int)param_3 < 0" (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }" { (expression_statement "local_28 = 0x210;" (assignment_expression "local_28 = 0x210" identifier = number_literal) ;) (labeled_statement "LAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" statement_identifier : (if_statement "if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" if (parenthesized_expression "(iVar7 < 0)" ( (binary_expression "iVar7 < 0" identifier < number_literal) )) (compound_statement "{\n        param_3 = 0;\n      }" { (expression_statement "param_3 = 0;" (assignment_expression "param_3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" else (compound_statement "{\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" { (expression_statement "param_3 = 0;" (assignment_expression "param_3 = 0" identifier = number_literal) ;) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" identifier = identifier) ;) (if_statement "if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }" if (parenthesized_expression "(*param_2 != '\0' || param_2[1] != '\0')" ( (binary_expression "*param_2 != '\0' || param_2[1] != '\0'" (binary_expression "*param_2 != '\0'" (pointer_expression "*param_2" * identifier) != (char_literal "'\0'" ' escape_sequence ')) || (binary_expression "param_2[1] != '\0'" (subscript_expression "param_2[1]" identifier [ number_literal ]) != (char_literal "'\0'" ' escape_sequence '))) )) (compound_statement "{\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }" { (do_statement "do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');" do (compound_statement "{\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          }" { (expression_statement "param_3 = sVar6 + 2;" (assignment_expression "param_3 = sVar6 + 2" identifier = (binary_expression "sVar6 + 2" identifier + number_literal)) ;) (if_statement "if (iVar7 < (int)param_3) break;" if (parenthesized_expression "(iVar7 < (int)param_3)" ( (binary_expression "iVar7 < (int)param_3" identifier < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) (break_statement "break;" break ;)) (expression_statement "iVar4 = sVar6 + 3;" (assignment_expression "iVar4 = sVar6 + 3" identifier = (binary_expression "sVar6 + 3" identifier + number_literal)) ;) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" identifier = identifier) ;) }) while (parenthesized_expression "(param_2[param_3] != '\0' || param_2[iVar4] != '\0')" ( (binary_expression "param_2[param_3] != '\0' || param_2[iVar4] != '\0'" (binary_expression "param_2[param_3] != '\0'" (subscript_expression "param_2[param_3]" identifier [ identifier ]) != (char_literal "'\0'" ' escape_sequence ')) || (binary_expression "param_2[iVar4] != '\0'" (subscript_expression "param_2[iVar4]" identifier [ identifier ]) != (char_literal "'\0'" ' escape_sequence '))) )) ;) })) })))) (if_statement "if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" if (parenthesized_expression "(param_5 == (code *)0xffffffff)" ( (binary_expression "param_5 == (code *)0xffffffff" identifier == (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" { (expression_statement "iVar4 = 2;" (assignment_expression "iVar4 = 2" identifier = number_literal) ;) (goto_statement "goto LAB_00045582;" goto statement_identifier ;) })) }) (else_clause "else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" else (compound_statement "{\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" { (expression_statement "local_28 = 0x10;" (assignment_expression "local_28 = 0x10" identifier = number_literal) ;) (if_statement "if (param_5 == (code *)0xffffffff) goto LAB_00045588;" if (parenthesized_expression "(param_5 == (code *)0xffffffff)" ( (binary_expression "param_5 == (code *)0xffffffff" identifier == (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_00045588;" goto statement_identifier ;)) }))) (labeled_statement "LAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;" statement_identifier : (expression_statement "uVar3 = *(ushort *)(param_1 + 8) & 0x2400;" (assignment_expression "uVar3 = *(ushort *)(param_1 + 8) & 0x2400" identifier = (binary_expression "*(ushort *)(param_1 + 8) & 0x2400" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) & number_literal)) ;)) (if_statement "if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" if (parenthesized_expression "(param_5 == FUN_00019850)" ( (binary_expression "param_5 == FUN_00019850" identifier == identifier) )) (compound_statement "{\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }" { (if_statement "if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }" if (parenthesized_expression "((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0))" ( (binary_expression "(uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)" (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) || (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" ( (binary_expression "*(int *)(param_1 + 0x18) != 0" (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) )))) != number_literal) ))) )) (compound_statement "{\n        FUN_00025180();\n      }" { (expression_statement "FUN_00025180();" (call_expression "FUN_00025180()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "*(char **)(param_1 + 0x10) = param_2;" (assignment_expression "*(char **)(param_1 + 0x10) = param_2" (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(char **)(param_1 + 0x14) = param_2;" (assignment_expression "*(char **)(param_1 + 0x14) = param_2" (pointer_expression "*(char **)(param_1 + 0x14)" * (cast_expression "(char **)(param_1 + 0x14)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) )))) = identifier) ;) (expression_statement "uVar5 = (*DAT_001491b8)(param_2);" (assignment_expression "uVar5 = (*DAT_001491b8)(param_2)" identifier = (call_expression "(*DAT_001491b8)(param_2)" (parenthesized_expression "(*DAT_001491b8)" ( (pointer_expression "*DAT_001491b8" * identifier) )) (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x18) = uVar5;" (assignment_expression "*(undefined4 *)(param_1 + 0x18) = uVar5" (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) )))) = identifier) ;) }) (else_clause "else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" else (compound_statement "{\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" { (if_statement "if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }" if (parenthesized_expression "((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0))" ( (binary_expression "(uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)" (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) || (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" ( (binary_expression "*(int *)(param_1 + 0x18) != 0" (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) )))) != number_literal) ))) )) (compound_statement "{\n        FUN_00025180();\n      }" { (expression_statement "FUN_00025180();" (call_expression "FUN_00025180()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "*(char **)(param_1 + 0x10) = param_2;" (assignment_expression "*(char **)(param_1 + 0x10) = param_2" (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(code **)(param_1 + 0x24) = param_5;" (assignment_expression "*(code **)(param_1 + 0x24) = param_5" (pointer_expression "*(code **)(param_1 + 0x24)" * (cast_expression "(code **)(param_1 + 0x24)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x24)" ( (binary_expression "param_1 + 0x24" identifier + number_literal) )))) = identifier) ;) (expression_statement "local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;" (assignment_expression "local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" identifier = (binary_expression "local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" identifier | (binary_expression "(-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" (parenthesized_expression "(-(ushort)(param_5 == (code *)0x0) & 0x400)" ( (binary_expression "-(ushort)(param_5 == (code *)0x0) & 0x400" (unary_expression "-(ushort)(param_5 == (code *)0x0)" - (call_expression "(ushort)(param_5 == (code *)0x0)" (parenthesized_expression "(ushort)" ( identifier )) (argument_list "(param_5 == (code *)0x0)" ( (binary_expression "param_5 == (code *)0x0" identifier == (cast_expression "(code *)0x0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )))) & number_literal) )) + number_literal))) ;) }))) }) (else_clause "else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" else (compound_statement "{\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" { (expression_statement "local_28 = 2;" (assignment_expression "local_28 = 2" identifier = number_literal) ;) (if_statement "if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" if (parenthesized_expression "((int)param_3 < 0)" ( (binary_expression "(int)param_3 < 0" (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }" { (if_statement "if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" if (parenthesized_expression "(param_4 != '\x01')" ( (binary_expression "param_4 != '\x01'" identifier != (char_literal "'\x01'" ' escape_sequence ')) )) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" { (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (goto_statement "goto LAB_0004554a;" goto statement_identifier ;) })) (expression_statement "param_3 = strlen(param_2);" (assignment_expression "param_3 = strlen(param_2)" identifier = (call_expression "strlen(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }" if (parenthesized_expression "(iVar7 < (int)param_3)" ( (binary_expression "iVar7 < (int)param_3" identifier < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n        param_3 = iVar7 + 1;\n      }" { (expression_statement "param_3 = iVar7 + 1;" (assignment_expression "param_3 = iVar7 + 1" identifier = (binary_expression "iVar7 + 1" identifier + number_literal)) ;) })) (if_statement "if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" if (parenthesized_expression "(param_5 != (code *)0xffffffff)" ( (binary_expression "param_5 != (code *)0xffffffff" identifier != (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" { (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (goto_statement "goto LAB_000453ae;" goto statement_identifier ;) })) (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (expression_statement "iVar4 = 1;" (assignment_expression "iVar4 = 1" identifier = number_literal) ;) (labeled_statement "LAB_00045582:\n      sVar6 = param_3 + iVar4;" statement_identifier : (expression_statement "sVar6 = param_3 + iVar4;" (assignment_expression "sVar6 = param_3 + iVar4" identifier = (binary_expression "param_3 + iVar4" identifier + identifier)) ;)) (expression_statement "local_24 = param_3;" (assignment_expression "local_24 = param_3" identifier = identifier) ;) }) (else_clause "else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" else (if_statement "if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" if (parenthesized_expression "(param_5 != (code *)0xffffffff)" ( (binary_expression "param_5 != (code *)0xffffffff" identifier != (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_000453ae;" goto statement_identifier ;)))) (labeled_statement "LAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }" statement_identifier : (if_statement "if (iVar7 < (int)local_24) {\n      return 0x12;\n    }" if (parenthesized_expression "(iVar7 < (int)local_24)" ( (binary_expression "iVar7 < (int)local_24" identifier < (cast_expression "(int)local_24" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      return 0x12;\n    }" { (return_statement "return 0x12;" return number_literal ;) }))) (expression_statement "sVar8 = 0x20;" (assignment_expression "sVar8 = 0x20" identifier = number_literal) ;) (if_statement "if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }" if (parenthesized_expression "(0x1f < (int)sVar6)" ( (binary_expression "0x1f < (int)sVar6" number_literal < (cast_expression "(int)sVar6" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      sVar8 = sVar6;\n    }" { (expression_statement "sVar8 = sVar6;" (assignment_expression "sVar8 = sVar6" identifier = identifier) ;) })) (if_statement "if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" if (parenthesized_expression "(*(int *)(param_1 + 0x18) < (int)sVar8)" ( (binary_expression "*(int *)(param_1 + 0x18) < (int)sVar8" (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) )))) < (cast_expression "(int)sVar8" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }" { (expression_statement "iVar4 = FUN_00044790();" (assignment_expression "iVar4 = FUN_00044790()" identifier = (call_expression "FUN_00044790()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        return 7;\n      }" { (return_statement "return 7;" return number_literal ;) })) (expression_statement "__dest = *(void **)(param_1 + 0x10);" (assignment_expression "__dest = *(void **)(param_1 + 0x10)" identifier = (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) }) (else_clause "else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" else (compound_statement "{\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" { (expression_statement "__dest = *(void **)(param_1 + 0x14);" (assignment_expression "__dest = *(void **)(param_1 + 0x14)" identifier = (pointer_expression "*(void **)(param_1 + 0x14)" * (cast_expression "(void **)(param_1 + 0x14)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) ;) (expression_statement "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;" (assignment_expression "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = (binary_expression "*(ushort *)(param_1 + 8) & 0xd" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) & number_literal)) ;) (expression_statement "*(void **)(param_1 + 0x10) = __dest;" (assignment_expression "*(void **)(param_1 + 0x10) = __dest" (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = identifier) ;) }))) (expression_statement "memcpy(__dest,param_2,sVar6);" (call_expression "memcpy(__dest,param_2,sVar6)" identifier (argument_list "(__dest,param_2,sVar6)" ( identifier , identifier , identifier ))) ;) (expression_statement "param_3 = local_24;" (assignment_expression "param_3 = local_24" identifier = identifier) ;) }))) (expression_statement "*(size_t *)(param_1 + 0xc) = param_3;" (assignment_expression "*(size_t *)(param_1 + 0xc) = param_3" (pointer_expression "*(size_t *)(param_1 + 0xc)" * (cast_expression "(size_t *)(param_1 + 0xc)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(ushort *)(param_1 + 8) = local_28;" (assignment_expression "*(ushort *)(param_1 + 8) = local_28" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = identifier) ;) (if_statement "if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" if (parenthesized_expression "(param_4 == '\0')" ( (binary_expression "param_4 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    *(undefined1 *)(param_1 + 10) = 1;\n  }" { (expression_statement "*(undefined1 *)(param_1 + 10) = 1;" (assignment_expression "*(undefined1 *)(param_1 + 10) = 1" (pointer_expression "*(undefined1 *)(param_1 + 10)" * (cast_expression "(undefined1 *)(param_1 + 10)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 10)" ( (binary_expression "param_1 + 10" identifier + number_literal) )))) = number_literal) ;) }) (else_clause "else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" else (compound_statement "{\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" { (expression_statement "*(char *)(param_1 + 10) = param_4;" (assignment_expression "*(char *)(param_1 + 10) = param_4" (pointer_expression "*(char *)(param_1 + 10)" * (cast_expression "(char *)(param_1 + 10)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 10)" ( (binary_expression "param_1 + 10" identifier + number_literal) )))) = identifier) ;) (if_statement "if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }" if (parenthesized_expression "((1 < (int)param_3) && (param_4 != '\x01'))" ( (binary_expression "(1 < (int)param_3) && (param_4 != '\x01')" (parenthesized_expression "(1 < (int)param_3)" ( (binary_expression "1 < (int)param_3" number_literal < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) && (parenthesized_expression "(param_4 != '\x01')" ( (binary_expression "param_4 != '\x01'" identifier != (char_literal "'\x01'" ' escape_sequence ')) ))) )) (compound_statement "{\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }" { (expression_statement "cVar1 = **(char **)(param_1 + 0x10);" (assignment_expression "cVar1 = **(char **)(param_1 + 0x10)" identifier = (pointer_expression "**(char **)(param_1 + 0x10)" * (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))))) ;) (expression_statement "cVar2 = (*(char **)(param_1 + 0x10))[1];" (assignment_expression "cVar2 = (*(char **)(param_1 + 0x10))[1]" identifier = (subscript_expression "(*(char **)(param_1 + 0x10))[1]" (parenthesized_expression "(*(char **)(param_1 + 0x10))" ( (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) )) [ number_literal ])) ;) (if_statement "if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }" if (parenthesized_expression "((cVar1 != -2) || (uVar9 = 3, cVar2 != -1))" ( (binary_expression "(cVar1 != -2) || (uVar9 = 3, cVar2 != -1)" (parenthesized_expression "(cVar1 != -2)" ( (binary_expression "cVar1 != -2" identifier != number_literal) )) || (parenthesized_expression "(uVar9 = 3, cVar2 != -1)" ( (comma_expression "uVar9 = 3, cVar2 != -1" (assignment_expression "uVar9 = 3" identifier = number_literal) , (binary_expression "cVar2 != -1" identifier != number_literal)) ))) )) (compound_statement "{\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }" { (if_statement "if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;" if (parenthesized_expression "((cVar1 != -1) || (cVar2 != -2))" ( (binary_expression "(cVar1 != -1) || (cVar2 != -2)" (parenthesized_expression "(cVar1 != -1)" ( (binary_expression "cVar1 != -1" identifier != number_literal) )) || (parenthesized_expression "(cVar2 != -2)" ( (binary_expression "cVar2 != -2" identifier != number_literal) ))) )) (goto_statement "goto LAB_00045408;" goto statement_identifier ;)) (expression_statement "uVar9 = 2;" (assignment_expression "uVar9 = 2" identifier = number_literal) ;) })) (expression_statement "iVar4 = FUN_000452f0();" (assignment_expression "iVar4 = FUN_000452f0()" identifier = (call_expression "FUN_000452f0()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        return 7;\n      }" { (return_statement "return 7;" return number_literal ;) })) (expression_statement "sVar6 = *(int *)(param_1 + 0xc) - 2;" (assignment_expression "sVar6 = *(int *)(param_1 + 0xc) - 2" identifier = (binary_expression "*(int *)(param_1 + 0xc) - 2" (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) )))) - number_literal)) ;) (expression_statement "*(size_t *)(param_1 + 0xc) = sVar6;" (assignment_expression "*(size_t *)(param_1 + 0xc) = sVar6" (pointer_expression "*(size_t *)(param_1 + 0xc)" * (cast_expression "(size_t *)(param_1 + 0xc)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = identifier) ;) (expression_statement "memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);" (call_expression "memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6)" identifier (argument_list "(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6)" ( (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) , (cast_expression "(void *)((int)*(void **)(param_1 + 0x10) + 2)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*(void **)(param_1 + 0x10) + 2)" ( (binary_expression "(int)*(void **)(param_1 + 0x10) + 2" (cast_expression "(int)*(void **)(param_1 + 0x10)" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) + number_literal) ))) , identifier ))) ;) (expression_statement "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;" (assignment_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0" (pointer_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" * (cast_expression "(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" ( (binary_expression "*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)" (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) )))) + (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) ))))) )))) = number_literal) ;) (expression_statement "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;" (assignment_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0" (pointer_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" * (cast_expression "(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" ( (binary_expression "*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)" (binary_expression "*(int *)(param_1 + 0x10) + 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) )))) + number_literal) + (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) ))))) )))) = number_literal) ;) (expression_statement "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;" (assignment_expression "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = (binary_expression "*(ushort *)(param_1 + 8) | 0x200" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) | number_literal)) ;) (expression_statement "*(undefined1 *)(param_1 + 10) = uVar9;" (assignment_expression "*(undefined1 *)(param_1 + 10) = uVar9" (pointer_expression "*(undefined1 *)(param_1 + 10)" * (cast_expression "(undefined1 *)(param_1 + 10)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 10)" ( (binary_expression "param_1 + 10" identifier + number_literal) )))) = identifier) ;) })) }))) (labeled_statement "LAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }" statement_identifier : (if_statement "if (iVar7 < (int)param_3) {\n    return 0x12;\n  }" if (parenthesized_expression "(iVar7 < (int)param_3)" ( (binary_expression "iVar7 < (int)param_3" identifier < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n    return 0x12;\n  }" { (return_statement "return 0x12;" return number_literal ;) }))) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint __regparm3 sqlite3VdbeMemSetStr(Mem *pMem,char *z,int n,u8 enc,_func_void_void_ptr *xDel)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  char *__dest;\n  size_t sVar5;\n  int iVar6;\n  size_t szNew;\n  u8 uVar7;\n  ushort local_28;\n  size_t local_24;\n  \n  if (z == (char *)0x0) {\n    if ((pMem->flags & 0x2400) != 0) {\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }\n    pMem->flags = 1;\n    return 0;\n  }\n  iVar6 = 1000000000;\n  if (pMem->db != (sqlite3 *)0x0) {\n    iVar6 = pMem->db->aLimit[0];\n  }\n  sVar5 = n;\n  local_24 = n;\n  if (enc == '\0') {\n    if (n < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = pMem->flags & 0x2400;\n    if (xDel == sqlite3MallocSize) {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }\n    else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }\n    szNew = 0x20;\n    if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }\n    if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }\n    memcpy(__dest,z,sVar5);\n    n = local_24;\n  }\n  pMem->n = n;\n  pMem->flags = local_28;\n  if (enc == '\0') {\n    pMem->enc = '\x01';\n  }\n  else {\n    pMem->enc = enc;\n    if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }\n  }\nLAB_00045408:\n  if (iVar6 < n) {\n    return 0x12;\n  }\n  return 0;\n}\n\n" comment (function_definition "int __regparm3 sqlite3VdbeMemSetStr(Mem *pMem,char *z,int n,u8 enc,_func_void_void_ptr *xDel)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  char *__dest;\n  size_t sVar5;\n  int iVar6;\n  size_t szNew;\n  u8 uVar7;\n  ushort local_28;\n  size_t local_24;\n  \n  if (z == (char *)0x0) {\n    if ((pMem->flags & 0x2400) != 0) {\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }\n    pMem->flags = 1;\n    return 0;\n  }\n  iVar6 = 1000000000;\n  if (pMem->db != (sqlite3 *)0x0) {\n    iVar6 = pMem->db->aLimit[0];\n  }\n  sVar5 = n;\n  local_24 = n;\n  if (enc == '\0') {\n    if (n < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = pMem->flags & 0x2400;\n    if (xDel == sqlite3MallocSize) {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }\n    else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }\n    szNew = 0x20;\n    if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }\n    if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }\n    memcpy(__dest,z,sVar5);\n    n = local_24;\n  }\n  pMem->n = n;\n  pMem->flags = local_28;\n  if (enc == '\0') {\n    pMem->enc = '\x01';\n  }\n  else {\n    pMem->enc = enc;\n    if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }\n  }\nLAB_00045408:\n  if (iVar6 < n) {\n    return 0x12;\n  }\n  return 0;\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "sqlite3VdbeMemSetStr(Mem *pMem,char *z,int n,u8 enc,_func_void_void_ptr *xDel)" identifier (parameter_list "(Mem *pMem,char *z,int n,u8 enc,_func_void_void_ptr *xDel)" ( (parameter_declaration "Mem *pMem" type_identifier (pointer_declarator "*pMem" * identifier)) , (parameter_declaration "char *z" primitive_type (pointer_declarator "*z" * identifier)) , (parameter_declaration "int n" primitive_type identifier) , (parameter_declaration "u8 enc" type_identifier identifier) , (parameter_declaration "_func_void_void_ptr *xDel" type_identifier (pointer_declarator "*xDel" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  char *__dest;\n  size_t sVar5;\n  int iVar6;\n  size_t szNew;\n  u8 uVar7;\n  ushort local_28;\n  size_t local_24;\n  \n  if (z == (char *)0x0) {\n    if ((pMem->flags & 0x2400) != 0) {\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }\n    pMem->flags = 1;\n    return 0;\n  }\n  iVar6 = 1000000000;\n  if (pMem->db != (sqlite3 *)0x0) {\n    iVar6 = pMem->db->aLimit[0];\n  }\n  sVar5 = n;\n  local_24 = n;\n  if (enc == '\0') {\n    if (n < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = pMem->flags & 0x2400;\n    if (xDel == sqlite3MallocSize) {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }\n    else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }\n    szNew = 0x20;\n    if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }\n    if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }\n    memcpy(__dest,z,sVar5);\n    n = local_24;\n  }\n  pMem->n = n;\n  pMem->flags = local_28;\n  if (enc == '\0') {\n    pMem->enc = '\x01';\n  }\n  else {\n    pMem->enc = enc;\n    if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }\n  }\nLAB_00045408:\n  if (iVar6 < n) {\n    return 0x12;\n  }\n  return 0;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "char cVar2;" primitive_type identifier ;) (declaration "ushort uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "char *__dest;" primitive_type (pointer_declarator "*__dest" * identifier) ;) (declaration "size_t sVar5;" primitive_type identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "size_t szNew;" primitive_type identifier ;) (declaration "u8 uVar7;" type_identifier identifier ;) (declaration "ushort local_28;" type_identifier identifier ;) (declaration "size_t local_24;" primitive_type identifier ;) (if_statement "if (z == (char *)0x0) {\n    if ((pMem->flags & 0x2400) != 0) {\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }\n    pMem->flags = 1;\n    return 0;\n  }" if (parenthesized_expression "(z == (char *)0x0)" ( (binary_expression "z == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if ((pMem->flags & 0x2400) != 0) {\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }\n    pMem->flags = 1;\n    return 0;\n  }" { (if_statement "if ((pMem->flags & 0x2400) != 0) {\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }" if (parenthesized_expression "((pMem->flags & 0x2400) != 0)" ( (binary_expression "(pMem->flags & 0x2400) != 0" (parenthesized_expression "(pMem->flags & 0x2400)" ( (binary_expression "pMem->flags & 0x2400" (field_expression "pMem->flags" identifier -> field_identifier) & number_literal) )) != number_literal) )) (compound_statement "{\n      vdbeMemClearExternAndSetNull(pMem);\n      return 0;\n    }" { (expression_statement "vdbeMemClearExternAndSetNull(pMem);" (call_expression "vdbeMemClearExternAndSetNull(pMem)" identifier (argument_list "(pMem)" ( identifier ))) ;) (return_statement "return 0;" return number_literal ;) })) (expression_statement "pMem->flags = 1;" (assignment_expression "pMem->flags = 1" (field_expression "pMem->flags" identifier -> field_identifier) = number_literal) ;) (return_statement "return 0;" return number_literal ;) })) (expression_statement "iVar6 = 1000000000;" (assignment_expression "iVar6 = 1000000000" identifier = number_literal) ;) (if_statement "if (pMem->db != (sqlite3 *)0x0) {\n    iVar6 = pMem->db->aLimit[0];\n  }" if (parenthesized_expression "(pMem->db != (sqlite3 *)0x0)" ( (binary_expression "pMem->db != (sqlite3 *)0x0" (field_expression "pMem->db" identifier -> field_identifier) != (cast_expression "(sqlite3 *)0x0" ( (type_descriptor "sqlite3 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    iVar6 = pMem->db->aLimit[0];\n  }" { (expression_statement "iVar6 = pMem->db->aLimit[0];" (assignment_expression "iVar6 = pMem->db->aLimit[0]" identifier = (subscript_expression "pMem->db->aLimit[0]" (field_expression "pMem->db->aLimit" (field_expression "pMem->db" identifier -> field_identifier) -> field_identifier) [ number_literal ])) ;) })) (expression_statement "sVar5 = n;" (assignment_expression "sVar5 = n" identifier = identifier) ;) (expression_statement "local_24 = n;" (assignment_expression "local_24 = n" identifier = identifier) ;) (if_statement "if (enc == '\0') {\n    if (n < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = pMem->flags & 0x2400;\n    if (xDel == sqlite3MallocSize) {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }\n    else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }\n    szNew = 0x20;\n    if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }\n    if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }\n    memcpy(__dest,z,sVar5);\n    n = local_24;\n  }" if (parenthesized_expression "(enc == '\0')" ( (binary_expression "enc == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    if (n < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = pMem->flags & 0x2400;\n    if (xDel == sqlite3MallocSize) {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }\n    else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }\n  }" { (if_statement "if (n < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }" if (parenthesized_expression "(n < 0)" ( (binary_expression "n < 0" identifier < number_literal) )) (compound_statement "{\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }" { (expression_statement "local_28 = 0x210;" (assignment_expression "local_28 = 0x210" identifier = number_literal) ;) (labeled_statement "LAB_0004554a:\n      if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }" statement_identifier : (if_statement "if (iVar6 < 0) {\n        n = 0;\n      }\n      else {\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }" if (parenthesized_expression "(iVar6 < 0)" ( (binary_expression "iVar6 < 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        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }" else (compound_statement "{\n        n = 0;\n        sVar5 = n;\n        if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }\n      }" { (expression_statement "n = 0;" (assignment_expression "n = 0" identifier = number_literal) ;) (expression_statement "sVar5 = n;" (assignment_expression "sVar5 = n" identifier = identifier) ;) (if_statement "if (*z != '\0' || z[1] != '\0') {\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }" if (parenthesized_expression "(*z != '\0' || z[1] != '\0')" ( (binary_expression "*z != '\0' || z[1] != '\0'" (binary_expression "*z != '\0'" (pointer_expression "*z" * identifier) != (char_literal "'\0'" ' escape_sequence ')) || (binary_expression "z[1] != '\0'" (subscript_expression "z[1]" identifier [ number_literal ]) != (char_literal "'\0'" ' escape_sequence '))) )) (compound_statement "{\n          do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');\n        }" { (do_statement "do {\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          } while (z[n] != '\0' || z[iVar4] != '\0');" do (compound_statement "{\n            n = sVar5 + 2;\n            if (iVar6 < n) break;\n            iVar4 = sVar5 + 3;\n            sVar5 = n;\n          }" { (expression_statement "n = sVar5 + 2;" (assignment_expression "n = sVar5 + 2" identifier = (binary_expression "sVar5 + 2" identifier + number_literal)) ;) (if_statement "if (iVar6 < n) break;" if (parenthesized_expression "(iVar6 < n)" ( (binary_expression "iVar6 < n" identifier < identifier) )) (break_statement "break;" break ;)) (expression_statement "iVar4 = sVar5 + 3;" (assignment_expression "iVar4 = sVar5 + 3" identifier = (binary_expression "sVar5 + 3" identifier + number_literal)) ;) (expression_statement "sVar5 = n;" (assignment_expression "sVar5 = n" identifier = identifier) ;) }) while (parenthesized_expression "(z[n] != '\0' || z[iVar4] != '\0')" ( (binary_expression "z[n] != '\0' || z[iVar4] != '\0'" (binary_expression "z[n] != '\0'" (subscript_expression "z[n]" identifier [ identifier ]) != (char_literal "'\0'" ' escape_sequence ')) || (binary_expression "z[iVar4] != '\0'" (subscript_expression "z[iVar4]" identifier [ identifier ]) != (char_literal "'\0'" ' escape_sequence '))) )) ;) })) })))) (if_statement "if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" if (parenthesized_expression "(xDel == (_func_void_void_ptr *)&DAT_ffffffff)" ( (binary_expression "xDel == (_func_void_void_ptr *)&DAT_ffffffff" identifier == (cast_expression "(_func_void_void_ptr *)&DAT_ffffffff" ( (type_descriptor "_func_void_void_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&DAT_ffffffff" & identifier))) )) (compound_statement "{\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" { (expression_statement "iVar4 = 2;" (assignment_expression "iVar4 = 2" identifier = number_literal) ;) (goto_statement "goto LAB_00045582;" goto statement_identifier ;) })) }) (else_clause "else {\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }" else (compound_statement "{\n      local_28 = 0x10;\n      if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;\n    }" { (expression_statement "local_28 = 0x10;" (assignment_expression "local_28 = 0x10" identifier = number_literal) ;) (if_statement "if (xDel == (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_00045588;" if (parenthesized_expression "(xDel == (_func_void_void_ptr *)&DAT_ffffffff)" ( (binary_expression "xDel == (_func_void_void_ptr *)&DAT_ffffffff" identifier == (cast_expression "(_func_void_void_ptr *)&DAT_ffffffff" ( (type_descriptor "_func_void_void_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&DAT_ffffffff" & identifier))) )) (goto_statement "goto LAB_00045588;" goto statement_identifier ;)) }))) (labeled_statement "LAB_000453ae:\n    uVar3 = pMem->flags & 0x2400;" statement_identifier : (expression_statement "uVar3 = pMem->flags & 0x2400;" (assignment_expression "uVar3 = pMem->flags & 0x2400" identifier = (binary_expression "pMem->flags & 0x2400" (field_expression "pMem->flags" identifier -> field_identifier) & number_literal)) ;)) (if_statement "if (xDel == sqlite3MallocSize) {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }\n    else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }" if (parenthesized_expression "(xDel == sqlite3MallocSize)" ( (binary_expression "xDel == sqlite3MallocSize" identifier == identifier) )) (compound_statement "{\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->zMalloc = z;\n      iVar4 = (*sqlite3Config.m.xSize)(z);\n      pMem->szMalloc = iVar4;\n    }" { (if_statement "if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }" if (parenthesized_expression "((uVar3 != 0) || (pMem->szMalloc != 0))" ( (binary_expression "(uVar3 != 0) || (pMem->szMalloc != 0)" (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) || (parenthesized_expression "(pMem->szMalloc != 0)" ( (binary_expression "pMem->szMalloc != 0" (field_expression "pMem->szMalloc" identifier -> field_identifier) != number_literal) ))) )) (compound_statement "{\n        vdbeMemClear(pMem);\n      }" { (expression_statement "vdbeMemClear(pMem);" (call_expression "vdbeMemClear(pMem)" identifier (argument_list "(pMem)" ( identifier ))) ;) })) (expression_statement "pMem->z = z;" (assignment_expression "pMem->z = z" (field_expression "pMem->z" identifier -> field_identifier) = identifier) ;) (expression_statement "pMem->zMalloc = z;" (assignment_expression "pMem->zMalloc = z" (field_expression "pMem->zMalloc" identifier -> field_identifier) = identifier) ;) (expression_statement "iVar4 = (*sqlite3Config.m.xSize)(z);" (assignment_expression "iVar4 = (*sqlite3Config.m.xSize)(z)" identifier = (call_expression "(*sqlite3Config.m.xSize)(z)" (parenthesized_expression "(*sqlite3Config.m.xSize)" ( (pointer_expression "*sqlite3Config.m.xSize" * (field_expression "sqlite3Config.m.xSize" (field_expression "sqlite3Config.m" identifier . field_identifier) . field_identifier)) )) (argument_list "(z)" ( identifier )))) ;) (expression_statement "pMem->szMalloc = iVar4;" (assignment_expression "pMem->szMalloc = iVar4" (field_expression "pMem->szMalloc" identifier -> field_identifier) = identifier) ;) }) (else_clause "else {\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }" else (compound_statement "{\n      if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }\n      pMem->z = z;\n      pMem->xDel = xDel;\n      local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;\n    }" { (if_statement "if ((uVar3 != 0) || (pMem->szMalloc != 0)) {\n        vdbeMemClear(pMem);\n      }" if (parenthesized_expression "((uVar3 != 0) || (pMem->szMalloc != 0))" ( (binary_expression "(uVar3 != 0) || (pMem->szMalloc != 0)" (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) || (parenthesized_expression "(pMem->szMalloc != 0)" ( (binary_expression "pMem->szMalloc != 0" (field_expression "pMem->szMalloc" identifier -> field_identifier) != number_literal) ))) )) (compound_statement "{\n        vdbeMemClear(pMem);\n      }" { (expression_statement "vdbeMemClear(pMem);" (call_expression "vdbeMemClear(pMem)" identifier (argument_list "(pMem)" ( identifier ))) ;) })) (expression_statement "pMem->z = z;" (assignment_expression "pMem->z = z" (field_expression "pMem->z" identifier -> field_identifier) = identifier) ;) (expression_statement "pMem->xDel = xDel;" (assignment_expression "pMem->xDel = xDel" (field_expression "pMem->xDel" identifier -> field_identifier) = identifier) ;) (expression_statement "local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400;" (assignment_expression "local_28 = local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400" identifier = (binary_expression "local_28 | (-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400" identifier | (binary_expression "(-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400) + 0x400" (parenthesized_expression "(-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400)" ( (binary_expression "-(ushort)(xDel == (_func_void_void_ptr *)0x0) & 0x400" (unary_expression "-(ushort)(xDel == (_func_void_void_ptr *)0x0)" - (call_expression "(ushort)(xDel == (_func_void_void_ptr *)0x0)" (parenthesized_expression "(ushort)" ( identifier )) (argument_list "(xDel == (_func_void_void_ptr *)0x0)" ( (binary_expression "xDel == (_func_void_void_ptr *)0x0" identifier == (cast_expression "(_func_void_void_ptr *)0x0" ( (type_descriptor "_func_void_void_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )))) & number_literal) )) + number_literal))) ;) }))) }) (else_clause "else {\n    local_28 = 2;\n    if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }\n    szNew = 0x20;\n    if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }\n    if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }\n    memcpy(__dest,z,sVar5);\n    n = local_24;\n  }" else (compound_statement "{\n    local_28 = 2;\n    if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }\n    szNew = 0x20;\n    if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }\n    if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }\n    memcpy(__dest,z,sVar5);\n    n = local_24;\n  }" { (expression_statement "local_28 = 2;" (assignment_expression "local_28 = 2" identifier = number_literal) ;) (if_statement "if (n < 0) {\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }\n    else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;" if (parenthesized_expression "(n < 0)" ( (binary_expression "n < 0" identifier < number_literal) )) (compound_statement "{\n      if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      n = strlen(z);\n      if (iVar6 < n) {\n        n = iVar6 + 1;\n      }\n      if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar5 = n + iVar4;\n      local_24 = n;\n    }" { (if_statement "if (enc != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" if (parenthesized_expression "(enc != '\x01')" ( (binary_expression "enc != '\x01'" identifier != (char_literal "'\x01'" ' escape_sequence ')) )) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" { (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (goto_statement "goto LAB_0004554a;" goto statement_identifier ;) })) (expression_statement "n = strlen(z);" (assignment_expression "n = strlen(z)" identifier = (call_expression "strlen(z)" identifier (argument_list "(z)" ( identifier )))) ;) (if_statement "if (iVar6 < n) {\n        n = iVar6 + 1;\n      }" if (parenthesized_expression "(iVar6 < n)" ( (binary_expression "iVar6 < n" identifier < identifier) )) (compound_statement "{\n        n = iVar6 + 1;\n      }" { (expression_statement "n = iVar6 + 1;" (assignment_expression "n = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) })) (if_statement "if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" if (parenthesized_expression "(xDel != (_func_void_void_ptr *)&DAT_ffffffff)" ( (binary_expression "xDel != (_func_void_void_ptr *)&DAT_ffffffff" identifier != (cast_expression "(_func_void_void_ptr *)&DAT_ffffffff" ( (type_descriptor "_func_void_void_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&DAT_ffffffff" & identifier))) )) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" { (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (goto_statement "goto LAB_000453ae;" goto statement_identifier ;) })) (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (expression_statement "iVar4 = 1;" (assignment_expression "iVar4 = 1" identifier = number_literal) ;) (labeled_statement "LAB_00045582:\n      sVar5 = n + iVar4;" statement_identifier : (expression_statement "sVar5 = n + iVar4;" (assignment_expression "sVar5 = n + iVar4" identifier = (binary_expression "n + iVar4" identifier + identifier)) ;)) (expression_statement "local_24 = n;" (assignment_expression "local_24 = n" identifier = identifier) ;) }) (else_clause "else if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;" else (if_statement "if (xDel != (_func_void_void_ptr *)&DAT_ffffffff) goto LAB_000453ae;" if (parenthesized_expression "(xDel != (_func_void_void_ptr *)&DAT_ffffffff)" ( (binary_expression "xDel != (_func_void_void_ptr *)&DAT_ffffffff" identifier != (cast_expression "(_func_void_void_ptr *)&DAT_ffffffff" ( (type_descriptor "_func_void_void_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&DAT_ffffffff" & identifier))) )) (goto_statement "goto LAB_000453ae;" goto statement_identifier ;)))) (labeled_statement "LAB_00045588:\n    if (iVar6 < (int)local_24) {\n      return 0x12;\n    }" statement_identifier : (if_statement "if (iVar6 < (int)local_24) {\n      return 0x12;\n    }" if (parenthesized_expression "(iVar6 < (int)local_24)" ( (binary_expression "iVar6 < (int)local_24" identifier < (cast_expression "(int)local_24" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      return 0x12;\n    }" { (return_statement "return 0x12;" return number_literal ;) }))) (expression_statement "szNew = 0x20;" (assignment_expression "szNew = 0x20" identifier = number_literal) ;) (if_statement "if (0x1f < (int)sVar5) {\n      szNew = sVar5;\n    }" if (parenthesized_expression "(0x1f < (int)sVar5)" ( (binary_expression "0x1f < (int)sVar5" number_literal < (cast_expression "(int)sVar5" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      szNew = sVar5;\n    }" { (expression_statement "szNew = sVar5;" (assignment_expression "szNew = sVar5" identifier = identifier) ;) })) (if_statement "if (pMem->szMalloc < (int)szNew) {\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }\n    else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }" if (parenthesized_expression "(pMem->szMalloc < (int)szNew)" ( (binary_expression "pMem->szMalloc < (int)szNew" (field_expression "pMem->szMalloc" identifier -> field_identifier) < (cast_expression "(int)szNew" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = pMem->z;\n    }" { (expression_statement "iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew);" (assignment_expression "iVar4 = sqlite3VdbeMemClearAndResize(pMem,szNew)" identifier = (call_expression "sqlite3VdbeMemClearAndResize(pMem,szNew)" identifier (argument_list "(pMem,szNew)" ( identifier , identifier )))) ;) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        return 7;\n      }" { (return_statement "return 7;" return number_literal ;) })) (expression_statement "__dest = pMem->z;" (assignment_expression "__dest = pMem->z" identifier = (field_expression "pMem->z" identifier -> field_identifier)) ;) }) (else_clause "else {\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }" else (compound_statement "{\n      __dest = pMem->zMalloc;\n      pMem->flags = pMem->flags & 0xd;\n      pMem->z = __dest;\n    }" { (expression_statement "__dest = pMem->zMalloc;" (assignment_expression "__dest = pMem->zMalloc" identifier = (field_expression "pMem->zMalloc" identifier -> field_identifier)) ;) (expression_statement "pMem->flags = pMem->flags & 0xd;" (assignment_expression "pMem->flags = pMem->flags & 0xd" (field_expression "pMem->flags" identifier -> field_identifier) = (binary_expression "pMem->flags & 0xd" (field_expression "pMem->flags" identifier -> field_identifier) & number_literal)) ;) (expression_statement "pMem->z = __dest;" (assignment_expression "pMem->z = __dest" (field_expression "pMem->z" identifier -> field_identifier) = identifier) ;) }))) (expression_statement "memcpy(__dest,z,sVar5);" (call_expression "memcpy(__dest,z,sVar5)" identifier (argument_list "(__dest,z,sVar5)" ( identifier , identifier , identifier ))) ;) (expression_statement "n = local_24;" (assignment_expression "n = local_24" identifier = identifier) ;) }))) (expression_statement "pMem->n = n;" (assignment_expression "pMem->n = n" (field_expression "pMem->n" identifier -> field_identifier) = identifier) ;) (expression_statement "pMem->flags = local_28;" (assignment_expression "pMem->flags = local_28" (field_expression "pMem->flags" identifier -> field_identifier) = identifier) ;) (if_statement "if (enc == '\0') {\n    pMem->enc = '\x01';\n  }\n  else {\n    pMem->enc = enc;\n    if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }\n  }" if (parenthesized_expression "(enc == '\0')" ( (binary_expression "enc == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    pMem->enc = '\x01';\n  }" { (expression_statement "pMem->enc = '\x01';" (assignment_expression "pMem->enc = '\x01'" (field_expression "pMem->enc" identifier -> field_identifier) = (char_literal "'\x01'" ' escape_sequence ')) ;) }) (else_clause "else {\n    pMem->enc = enc;\n    if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }\n  }" else (compound_statement "{\n    pMem->enc = enc;\n    if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }\n  }" { (expression_statement "pMem->enc = enc;" (assignment_expression "pMem->enc = enc" (field_expression "pMem->enc" identifier -> field_identifier) = identifier) ;) (if_statement "if ((1 < n) && (enc != '\x01')) {\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }" if (parenthesized_expression "((1 < n) && (enc != '\x01'))" ( (binary_expression "(1 < n) && (enc != '\x01')" (parenthesized_expression "(1 < n)" ( (binary_expression "1 < n" number_literal < identifier) )) && (parenthesized_expression "(enc != '\x01')" ( (binary_expression "enc != '\x01'" identifier != (char_literal "'\x01'" ' escape_sequence ')) ))) )) (compound_statement "{\n      cVar1 = *pMem->z;\n      cVar2 = pMem->z[1];\n      if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }\n      iVar4 = sqlite3VdbeMemMakeWriteable(pMem);\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar5 = pMem->n - 2;\n      pMem->n = sVar5;\n      memmove(pMem->z,pMem->z + 2,sVar5);\n      pMem->z[pMem->n] = '\0';\n      pMem->z[pMem->n + 1] = '\0';\n      pMem->flags = pMem->flags | 0x200;\n      pMem->enc = uVar7;\n    }" { (expression_statement "cVar1 = *pMem->z;" (assignment_expression "cVar1 = *pMem->z" identifier = (pointer_expression "*pMem->z" * (field_expression "pMem->z" identifier -> field_identifier))) ;) (expression_statement "cVar2 = pMem->z[1];" (assignment_expression "cVar2 = pMem->z[1]" identifier = (subscript_expression "pMem->z[1]" (field_expression "pMem->z" identifier -> field_identifier) [ number_literal ])) ;) (if_statement "if ((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }" if (parenthesized_expression "((cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1))" ( (binary_expression "(cVar1 != -2) || (uVar7 = '\x03', cVar2 != -1)" (parenthesized_expression "(cVar1 != -2)" ( (binary_expression "cVar1 != -2" identifier != number_literal) )) || (parenthesized_expression "(uVar7 = '\x03', cVar2 != -1)" ( (comma_expression "uVar7 = '\x03', cVar2 != -1" (assignment_expression "uVar7 = '\x03'" identifier = (char_literal "'\x03'" ' escape_sequence ')) , (binary_expression "cVar2 != -1" identifier != number_literal)) ))) )) (compound_statement "{\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar7 = '\x02';\n      }" { (if_statement "if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;" if (parenthesized_expression "((cVar1 != -1) || (cVar2 != -2))" ( (binary_expression "(cVar1 != -1) || (cVar2 != -2)" (parenthesized_expression "(cVar1 != -1)" ( (binary_expression "cVar1 != -1" identifier != number_literal) )) || (parenthesized_expression "(cVar2 != -2)" ( (binary_expression "cVar2 != -2" identifier != number_literal) ))) )) (goto_statement "goto LAB_00045408;" goto statement_identifier ;)) (expression_statement "uVar7 = '\x02';" (assignment_expression "uVar7 = '\x02'" identifier = (char_literal "'\x02'" ' escape_sequence ')) ;) })) (expression_statement "iVar4 = sqlite3VdbeMemMakeWriteable(pMem);" (assignment_expression "iVar4 = sqlite3VdbeMemMakeWriteable(pMem)" identifier = (call_expression "sqlite3VdbeMemMakeWriteable(pMem)" identifier (argument_list "(pMem)" ( identifier )))) ;) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        return 7;\n      }" { (return_statement "return 7;" return number_literal ;) })) (expression_statement "sVar5 = pMem->n - 2;" (assignment_expression "sVar5 = pMem->n - 2" identifier = (binary_expression "pMem->n - 2" (field_expression "pMem->n" identifier -> field_identifier) - number_literal)) ;) (expression_statement "pMem->n = sVar5;" (assignment_expression "pMem->n = sVar5" (field_expression "pMem->n" identifier -> field_identifier) = identifier) ;) (expression_statement "memmove(pMem->z,pMem->z + 2,sVar5);" (call_expression "memmove(pMem->z,pMem->z + 2,sVar5)" identifier (argument_list "(pMem->z,pMem->z + 2,sVar5)" ( (field_expression "pMem->z" identifier -> field_identifier) , (binary_expression "pMem->z + 2" (field_expression "pMem->z" identifier -> field_identifier) + number_literal) , identifier ))) ;) (expression_statement "pMem->z[pMem->n] = '\0';" (assignment_expression "pMem->z[pMem->n] = '\0'" (subscript_expression "pMem->z[pMem->n]" (field_expression "pMem->z" identifier -> field_identifier) [ (field_expression "pMem->n" identifier -> field_identifier) ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "pMem->z[pMem->n + 1] = '\0';" (assignment_expression "pMem->z[pMem->n + 1] = '\0'" (subscript_expression "pMem->z[pMem->n + 1]" (field_expression "pMem->z" identifier -> field_identifier) [ (binary_expression "pMem->n + 1" (field_expression "pMem->n" identifier -> field_identifier) + number_literal) ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "pMem->flags = pMem->flags | 0x200;" (assignment_expression "pMem->flags = pMem->flags | 0x200" (field_expression "pMem->flags" identifier -> field_identifier) = (binary_expression "pMem->flags | 0x200" (field_expression "pMem->flags" identifier -> field_identifier) | number_literal)) ;) (expression_statement "pMem->enc = uVar7;" (assignment_expression "pMem->enc = uVar7" (field_expression "pMem->enc" identifier -> field_identifier) = identifier) ;) })) }))) (labeled_statement "LAB_00045408:\n  if (iVar6 < n) {\n    return 0x12;\n  }" statement_identifier : (if_statement "if (iVar6 < n) {\n    return 0x12;\n  }" if (parenthesized_expression "(iVar6 < n)" ( (binary_expression "iVar6 < n" identifier < identifier) )) (compound_statement "{\n    return 0x12;\n  }" { (return_statement "return 0x12;" return number_literal ;) }))) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "undefined4 __regparm3\nFUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}\n\n" (function_definition "undefined4 __regparm3\nFUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)" identifier (parameter_list "(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "size_t param_3" primitive_type identifier) , (parameter_declaration "char param_4" primitive_type identifier) , (parameter_declaration "code *param_5" type_identifier (pointer_declarator "*param_5" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "char cVar2;" primitive_type identifier ;) (declaration "ushort uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "undefined4 uVar5;" type_identifier identifier ;) (declaration "void *__dest;" primitive_type (pointer_declarator "*__dest" * identifier) ;) (declaration "size_t sVar6;" primitive_type identifier ;) (declaration "int iVar7;" primitive_type identifier ;) (declaration "size_t sVar8;" primitive_type identifier ;) (declaration "undefined1 uVar9;" type_identifier identifier ;) (declaration "ushort local_28;" type_identifier identifier ;) (declaration "size_t local_24;" primitive_type identifier ;) (if_statement "if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }" if (parenthesized_expression "(param_2 == (char *)0x0)" ( (binary_expression "param_2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }" { (if_statement "if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }" if (parenthesized_expression "((*(ushort *)(param_1 + 8) & 0x2400) != 0)" ( (binary_expression "(*(ushort *)(param_1 + 8) & 0x2400) != 0" (parenthesized_expression "(*(ushort *)(param_1 + 8) & 0x2400)" ( (binary_expression "*(ushort *)(param_1 + 8) & 0x2400" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n      FUN_00024f00();\n      return 0;\n    }" { (expression_statement "FUN_00024f00();" (call_expression "FUN_00024f00()" identifier (argument_list "()" ( ))) ;) (return_statement "return 0;" return number_literal ;) })) (expression_statement "*(undefined2 *)(param_1 + 8) = 1;" (assignment_expression "*(undefined2 *)(param_1 + 8) = 1" (pointer_expression "*(undefined2 *)(param_1 + 8)" * (cast_expression "(undefined2 *)(param_1 + 8)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = number_literal) ;) (return_statement "return 0;" return number_literal ;) })) (expression_statement "iVar7 = 1000000000;" (assignment_expression "iVar7 = 1000000000" identifier = number_literal) ;) (if_statement "if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x20) != 0)" ( (binary_expression "*(int *)(param_1 + 0x20) != 0" (pointer_expression "*(int *)(param_1 + 0x20)" * (cast_expression "(int *)(param_1 + 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x20)" ( (binary_expression "param_1 + 0x20" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }" { (expression_statement "iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);" (assignment_expression "iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68)" identifier = (pointer_expression "*(int *)(*(int *)(param_1 + 0x20) + 0x68)" * (cast_expression "(int *)(*(int *)(param_1 + 0x20) + 0x68)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(param_1 + 0x20) + 0x68)" ( (binary_expression "*(int *)(param_1 + 0x20) + 0x68" (pointer_expression "*(int *)(param_1 + 0x20)" * (cast_expression "(int *)(param_1 + 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x20)" ( (binary_expression "param_1 + 0x20" identifier + number_literal) )))) + number_literal) ))))) ;) })) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" identifier = identifier) ;) (expression_statement "local_24 = param_3;" (assignment_expression "local_24 = param_3" identifier = identifier) ;) (if_statement "if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" if (parenthesized_expression "(param_4 == '\0')" ( (binary_expression "param_4 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }" { (if_statement "if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" if (parenthesized_expression "((int)param_3 < 0)" ( (binary_expression "(int)param_3 < 0" (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }" { (expression_statement "local_28 = 0x210;" (assignment_expression "local_28 = 0x210" identifier = number_literal) ;) (labeled_statement "LAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" statement_identifier : (if_statement "if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" if (parenthesized_expression "(iVar7 < 0)" ( (binary_expression "iVar7 < 0" identifier < number_literal) )) (compound_statement "{\n        param_3 = 0;\n      }" { (expression_statement "param_3 = 0;" (assignment_expression "param_3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" else (compound_statement "{\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" { (expression_statement "param_3 = 0;" (assignment_expression "param_3 = 0" identifier = number_literal) ;) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" identifier = identifier) ;) (if_statement "if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }" if (parenthesized_expression "(*param_2 != '\0' || param_2[1] != '\0')" ( (binary_expression "*param_2 != '\0' || param_2[1] != '\0'" (binary_expression "*param_2 != '\0'" (pointer_expression "*param_2" * identifier) != (char_literal "'\0'" ' escape_sequence ')) || (binary_expression "param_2[1] != '\0'" (subscript_expression "param_2[1]" identifier [ number_literal ]) != (char_literal "'\0'" ' escape_sequence '))) )) (compound_statement "{\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }" { (do_statement "do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');" do (compound_statement "{\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          }" { (expression_statement "param_3 = sVar6 + 2;" (assignment_expression "param_3 = sVar6 + 2" identifier = (binary_expression "sVar6 + 2" identifier + number_literal)) ;) (if_statement "if (iVar7 < (int)param_3) break;" if (parenthesized_expression "(iVar7 < (int)param_3)" ( (binary_expression "iVar7 < (int)param_3" identifier < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) (break_statement "break;" break ;)) (expression_statement "iVar4 = sVar6 + 3;" (assignment_expression "iVar4 = sVar6 + 3" identifier = (binary_expression "sVar6 + 3" identifier + number_literal)) ;) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" identifier = identifier) ;) }) while (parenthesized_expression "(param_2[param_3] != '\0' || param_2[iVar4] != '\0')" ( (binary_expression "param_2[param_3] != '\0' || param_2[iVar4] != '\0'" (binary_expression "param_2[param_3] != '\0'" (subscript_expression "param_2[param_3]" identifier [ identifier ]) != (char_literal "'\0'" ' escape_sequence ')) || (binary_expression "param_2[iVar4] != '\0'" (subscript_expression "param_2[iVar4]" identifier [ identifier ]) != (char_literal "'\0'" ' escape_sequence '))) )) ;) })) })))) (if_statement "if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" if (parenthesized_expression "(param_5 == (code *)0xffffffff)" ( (binary_expression "param_5 == (code *)0xffffffff" identifier == (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" { (expression_statement "iVar4 = 2;" (assignment_expression "iVar4 = 2" identifier = number_literal) ;) (goto_statement "goto LAB_00045582;" goto statement_identifier ;) })) }) (else_clause "else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" else (compound_statement "{\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" { (expression_statement "local_28 = 0x10;" (assignment_expression "local_28 = 0x10" identifier = number_literal) ;) (if_statement "if (param_5 == (code *)0xffffffff) goto LAB_00045588;" if (parenthesized_expression "(param_5 == (code *)0xffffffff)" ( (binary_expression "param_5 == (code *)0xffffffff" identifier == (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_00045588;" goto statement_identifier ;)) }))) (labeled_statement "LAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;" statement_identifier : (expression_statement "uVar3 = *(ushort *)(param_1 + 8) & 0x2400;" (assignment_expression "uVar3 = *(ushort *)(param_1 + 8) & 0x2400" identifier = (binary_expression "*(ushort *)(param_1 + 8) & 0x2400" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) & number_literal)) ;)) (if_statement "if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" if (parenthesized_expression "(param_5 == FUN_00019850)" ( (binary_expression "param_5 == FUN_00019850" identifier == identifier) )) (compound_statement "{\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }" { (if_statement "if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }" if (parenthesized_expression "((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0))" ( (binary_expression "(uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)" (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) || (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" ( (binary_expression "*(int *)(param_1 + 0x18) != 0" (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) )))) != number_literal) ))) )) (compound_statement "{\n        FUN_00025180();\n      }" { (expression_statement "FUN_00025180();" (call_expression "FUN_00025180()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "*(char **)(param_1 + 0x10) = param_2;" (assignment_expression "*(char **)(param_1 + 0x10) = param_2" (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(char **)(param_1 + 0x14) = param_2;" (assignment_expression "*(char **)(param_1 + 0x14) = param_2" (pointer_expression "*(char **)(param_1 + 0x14)" * (cast_expression "(char **)(param_1 + 0x14)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) )))) = identifier) ;) (expression_statement "uVar5 = (*DAT_001491b8)(param_2);" (assignment_expression "uVar5 = (*DAT_001491b8)(param_2)" identifier = (call_expression "(*DAT_001491b8)(param_2)" (parenthesized_expression "(*DAT_001491b8)" ( (pointer_expression "*DAT_001491b8" * identifier) )) (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x18) = uVar5;" (assignment_expression "*(undefined4 *)(param_1 + 0x18) = uVar5" (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) )))) = identifier) ;) }) (else_clause "else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" else (compound_statement "{\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" { (if_statement "if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }" if (parenthesized_expression "((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0))" ( (binary_expression "(uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)" (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) || (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" ( (binary_expression "*(int *)(param_1 + 0x18) != 0" (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) )))) != number_literal) ))) )) (compound_statement "{\n        FUN_00025180();\n      }" { (expression_statement "FUN_00025180();" (call_expression "FUN_00025180()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "*(char **)(param_1 + 0x10) = param_2;" (assignment_expression "*(char **)(param_1 + 0x10) = param_2" (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(code **)(param_1 + 0x24) = param_5;" (assignment_expression "*(code **)(param_1 + 0x24) = param_5" (pointer_expression "*(code **)(param_1 + 0x24)" * (cast_expression "(code **)(param_1 + 0x24)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x24)" ( (binary_expression "param_1 + 0x24" identifier + number_literal) )))) = identifier) ;) (expression_statement "local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;" (assignment_expression "local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" identifier = (binary_expression "local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" identifier | (binary_expression "(-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" (parenthesized_expression "(-(ushort)(param_5 == (code *)0x0) & 0x400)" ( (binary_expression "-(ushort)(param_5 == (code *)0x0) & 0x400" (unary_expression "-(ushort)(param_5 == (code *)0x0)" - (call_expression "(ushort)(param_5 == (code *)0x0)" (parenthesized_expression "(ushort)" ( identifier )) (argument_list "(param_5 == (code *)0x0)" ( (binary_expression "param_5 == (code *)0x0" identifier == (cast_expression "(code *)0x0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )))) & number_literal) )) + number_literal))) ;) }))) }) (else_clause "else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" else (compound_statement "{\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" { (expression_statement "local_28 = 2;" (assignment_expression "local_28 = 2" identifier = number_literal) ;) (if_statement "if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" if (parenthesized_expression "((int)param_3 < 0)" ( (binary_expression "(int)param_3 < 0" (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier) < number_literal) )) (compound_statement "{\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }" { (if_statement "if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" if (parenthesized_expression "(param_4 != '\x01')" ( (binary_expression "param_4 != '\x01'" identifier != (char_literal "'\x01'" ' escape_sequence ')) )) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" { (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (goto_statement "goto LAB_0004554a;" goto statement_identifier ;) })) (expression_statement "param_3 = strlen(param_2);" (assignment_expression "param_3 = strlen(param_2)" identifier = (call_expression "strlen(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }" if (parenthesized_expression "(iVar7 < (int)param_3)" ( (binary_expression "iVar7 < (int)param_3" identifier < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n        param_3 = iVar7 + 1;\n      }" { (expression_statement "param_3 = iVar7 + 1;" (assignment_expression "param_3 = iVar7 + 1" identifier = (binary_expression "iVar7 + 1" identifier + number_literal)) ;) })) (if_statement "if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" if (parenthesized_expression "(param_5 != (code *)0xffffffff)" ( (binary_expression "param_5 != (code *)0xffffffff" identifier != (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" { (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (goto_statement "goto LAB_000453ae;" goto statement_identifier ;) })) (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" identifier = number_literal) ;) (expression_statement "iVar4 = 1;" (assignment_expression "iVar4 = 1" identifier = number_literal) ;) (labeled_statement "LAB_00045582:\n      sVar6 = param_3 + iVar4;" statement_identifier : (expression_statement "sVar6 = param_3 + iVar4;" (assignment_expression "sVar6 = param_3 + iVar4" identifier = (binary_expression "param_3 + iVar4" identifier + identifier)) ;)) (expression_statement "local_24 = param_3;" (assignment_expression "local_24 = param_3" identifier = identifier) ;) }) (else_clause "else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" else (if_statement "if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" if (parenthesized_expression "(param_5 != (code *)0xffffffff)" ( (binary_expression "param_5 != (code *)0xffffffff" identifier != (cast_expression "(code *)0xffffffff" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_000453ae;" goto statement_identifier ;)))) (labeled_statement "LAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }" statement_identifier : (if_statement "if (iVar7 < (int)local_24) {\n      return 0x12;\n    }" if (parenthesized_expression "(iVar7 < (int)local_24)" ( (binary_expression "iVar7 < (int)local_24" identifier < (cast_expression "(int)local_24" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      return 0x12;\n    }" { (return_statement "return 0x12;" return number_literal ;) }))) (expression_statement "sVar8 = 0x20;" (assignment_expression "sVar8 = 0x20" identifier = number_literal) ;) (if_statement "if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }" if (parenthesized_expression "(0x1f < (int)sVar6)" ( (binary_expression "0x1f < (int)sVar6" number_literal < (cast_expression "(int)sVar6" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      sVar8 = sVar6;\n    }" { (expression_statement "sVar8 = sVar6;" (assignment_expression "sVar8 = sVar6" identifier = identifier) ;) })) (if_statement "if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" if (parenthesized_expression "(*(int *)(param_1 + 0x18) < (int)sVar8)" ( (binary_expression "*(int *)(param_1 + 0x18) < (int)sVar8" (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) )))) < (cast_expression "(int)sVar8" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }" { (expression_statement "iVar4 = FUN_00044790();" (assignment_expression "iVar4 = FUN_00044790()" identifier = (call_expression "FUN_00044790()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        return 7;\n      }" { (return_statement "return 7;" return number_literal ;) })) (expression_statement "__dest = *(void **)(param_1 + 0x10);" (assignment_expression "__dest = *(void **)(param_1 + 0x10)" identifier = (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) }) (else_clause "else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" else (compound_statement "{\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" { (expression_statement "__dest = *(void **)(param_1 + 0x14);" (assignment_expression "__dest = *(void **)(param_1 + 0x14)" identifier = (pointer_expression "*(void **)(param_1 + 0x14)" * (cast_expression "(void **)(param_1 + 0x14)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) ;) (expression_statement "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;" (assignment_expression "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = (binary_expression "*(ushort *)(param_1 + 8) & 0xd" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) & number_literal)) ;) (expression_statement "*(void **)(param_1 + 0x10) = __dest;" (assignment_expression "*(void **)(param_1 + 0x10) = __dest" (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) = identifier) ;) }))) (expression_statement "memcpy(__dest,param_2,sVar6);" (call_expression "memcpy(__dest,param_2,sVar6)" identifier (argument_list "(__dest,param_2,sVar6)" ( identifier , identifier , identifier ))) ;) (expression_statement "param_3 = local_24;" (assignment_expression "param_3 = local_24" identifier = identifier) ;) }))) (expression_statement "*(size_t *)(param_1 + 0xc) = param_3;" (assignment_expression "*(size_t *)(param_1 + 0xc) = param_3" (pointer_expression "*(size_t *)(param_1 + 0xc)" * (cast_expression "(size_t *)(param_1 + 0xc)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(ushort *)(param_1 + 8) = local_28;" (assignment_expression "*(ushort *)(param_1 + 8) = local_28" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = identifier) ;) (if_statement "if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" if (parenthesized_expression "(param_4 == '\0')" ( (binary_expression "param_4 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    *(undefined1 *)(param_1 + 10) = 1;\n  }" { (expression_statement "*(undefined1 *)(param_1 + 10) = 1;" (assignment_expression "*(undefined1 *)(param_1 + 10) = 1" (pointer_expression "*(undefined1 *)(param_1 + 10)" * (cast_expression "(undefined1 *)(param_1 + 10)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 10)" ( (binary_expression "param_1 + 10" identifier + number_literal) )))) = number_literal) ;) }) (else_clause "else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" else (compound_statement "{\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" { (expression_statement "*(char *)(param_1 + 10) = param_4;" (assignment_expression "*(char *)(param_1 + 10) = param_4" (pointer_expression "*(char *)(param_1 + 10)" * (cast_expression "(char *)(param_1 + 10)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 10)" ( (binary_expression "param_1 + 10" identifier + number_literal) )))) = identifier) ;) (if_statement "if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }" if (parenthesized_expression "((1 < (int)param_3) && (param_4 != '\x01'))" ( (binary_expression "(1 < (int)param_3) && (param_4 != '\x01')" (parenthesized_expression "(1 < (int)param_3)" ( (binary_expression "1 < (int)param_3" number_literal < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) && (parenthesized_expression "(param_4 != '\x01')" ( (binary_expression "param_4 != '\x01'" identifier != (char_literal "'\x01'" ' escape_sequence ')) ))) )) (compound_statement "{\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }" { (expression_statement "cVar1 = **(char **)(param_1 + 0x10);" (assignment_expression "cVar1 = **(char **)(param_1 + 0x10)" identifier = (pointer_expression "**(char **)(param_1 + 0x10)" * (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))))) ;) (expression_statement "cVar2 = (*(char **)(param_1 + 0x10))[1];" (assignment_expression "cVar2 = (*(char **)(param_1 + 0x10))[1]" identifier = (subscript_expression "(*(char **)(param_1 + 0x10))[1]" (parenthesized_expression "(*(char **)(param_1 + 0x10))" ( (pointer_expression "*(char **)(param_1 + 0x10)" * (cast_expression "(char **)(param_1 + 0x10)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) )) [ number_literal ])) ;) (if_statement "if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }" if (parenthesized_expression "((cVar1 != -2) || (uVar9 = 3, cVar2 != -1))" ( (binary_expression "(cVar1 != -2) || (uVar9 = 3, cVar2 != -1)" (parenthesized_expression "(cVar1 != -2)" ( (binary_expression "cVar1 != -2" identifier != number_literal) )) || (parenthesized_expression "(uVar9 = 3, cVar2 != -1)" ( (comma_expression "uVar9 = 3, cVar2 != -1" (assignment_expression "uVar9 = 3" identifier = number_literal) , (binary_expression "cVar2 != -1" identifier != number_literal)) ))) )) (compound_statement "{\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }" { (if_statement "if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;" if (parenthesized_expression "((cVar1 != -1) || (cVar2 != -2))" ( (binary_expression "(cVar1 != -1) || (cVar2 != -2)" (parenthesized_expression "(cVar1 != -1)" ( (binary_expression "cVar1 != -1" identifier != number_literal) )) || (parenthesized_expression "(cVar2 != -2)" ( (binary_expression "cVar2 != -2" identifier != number_literal) ))) )) (goto_statement "goto LAB_00045408;" goto statement_identifier ;)) (expression_statement "uVar9 = 2;" (assignment_expression "uVar9 = 2" identifier = number_literal) ;) })) (expression_statement "iVar4 = FUN_000452f0();" (assignment_expression "iVar4 = FUN_000452f0()" identifier = (call_expression "FUN_000452f0()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        return 7;\n      }" { (return_statement "return 7;" return number_literal ;) })) (expression_statement "sVar6 = *(int *)(param_1 + 0xc) - 2;" (assignment_expression "sVar6 = *(int *)(param_1 + 0xc) - 2" identifier = (binary_expression "*(int *)(param_1 + 0xc) - 2" (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) )))) - number_literal)) ;) (expression_statement "*(size_t *)(param_1 + 0xc) = sVar6;" (assignment_expression "*(size_t *)(param_1 + 0xc) = sVar6" (pointer_expression "*(size_t *)(param_1 + 0xc)" * (cast_expression "(size_t *)(param_1 + 0xc)" ( (type_descriptor "size_t *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = identifier) ;) (expression_statement "memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);" (call_expression "memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6)" identifier (argument_list "(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6)" ( (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) , (cast_expression "(void *)((int)*(void **)(param_1 + 0x10) + 2)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*(void **)(param_1 + 0x10) + 2)" ( (binary_expression "(int)*(void **)(param_1 + 0x10) + 2" (cast_expression "(int)*(void **)(param_1 + 0x10)" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*(void **)(param_1 + 0x10)" * (cast_expression "(void **)(param_1 + 0x10)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) + number_literal) ))) , identifier ))) ;) (expression_statement "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;" (assignment_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0" (pointer_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" * (cast_expression "(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" ( (binary_expression "*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)" (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) )))) + (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) ))))) )))) = number_literal) ;) (expression_statement "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;" (assignment_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0" (pointer_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" * (cast_expression "(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" ( (binary_expression "*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)" (binary_expression "*(int *)(param_1 + 0x10) + 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) )))) + number_literal) + (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) ))))) )))) = number_literal) ;) (expression_statement "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;" (assignment_expression "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) = (binary_expression "*(ushort *)(param_1 + 8) | 0x200" (pointer_expression "*(ushort *)(param_1 + 8)" * (cast_expression "(ushort *)(param_1 + 8)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) | number_literal)) ;) (expression_statement "*(undefined1 *)(param_1 + 10) = uVar9;" (assignment_expression "*(undefined1 *)(param_1 + 10) = uVar9" (pointer_expression "*(undefined1 *)(param_1 + 10)" * (cast_expression "(undefined1 *)(param_1 + 10)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 10)" ( (binary_expression "param_1 + 10" identifier + number_literal) )))) = identifier) ;) })) }))) (labeled_statement "LAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }" statement_identifier : (if_statement "if (iVar7 < (int)param_3) {\n    return 0x12;\n  }" if (parenthesized_expression "(iVar7 < (int)param_3)" ( (binary_expression "iVar7 < (int)param_3" identifier < (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) )) (compound_statement "{\n    return 0x12;\n  }" { (return_statement "return 0x12;" return number_literal ;) }))) (return_statement "return 0;" return number_literal ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT) )) != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (return_statement return LIT ;) })) (expression_statement (assignment_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) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT) ))))) ;) })) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' escape_sequence ')) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (labeled_statement statement_identifier : (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) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression (pointer_expression * IDENT) != (char_literal ' escape_sequence ')) || (binary_expression (subscript_expression IDENT [ LIT ]) != (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 IDENT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression (binary_expression (subscript_expression IDENT [ IDENT ]) != (char_literal ' escape_sequence ')) || (binary_expression (subscript_expression IDENT [ IDENT ]) != (char_literal ' escape_sequence '))) )) ;) })) })))) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (goto_statement goto statement_identifier ;)) }))) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT)) ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT == IDENT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT | (binary_expression (parenthesized_expression ( (binary_expression (unary_expression - (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )))) & LIT) )) + LIT))) ;) }))) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;)) (expression_statement (assignment_expression IDENT = IDENT) ;) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (goto_statement goto statement_identifier ;)))) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression IDENT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) (compound_statement { (return_statement return LIT ;) }))) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) })) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (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) )))) = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = 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 (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = 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) )))) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression LIT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) && (parenthesized_expression ( (binary_expression IDENT != (char_literal ' escape_sequence ')) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))))) ;) (expression_statement (assignment_expression IDENT = (subscript_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) )) [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = LIT) , (binary_expression IDENT != LIT)) ))) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = LIT) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) - LIT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) + LIT) ))) , IDENT ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )))) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT) + (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )))) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) | LIT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) })) }))) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression IDENT < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) (compound_statement { (return_statement return LIT ;) }))) (return_statement return LIT ;) })))
(function_definition "undefined4 __regparm3\nFUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)\n\n{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}" (type_identifier "undefined4") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_00045350(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)" (identifier "FUN_00045350") (parameter_list "(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "char *param_2" (primitive_type "char") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "size_t param_3" (primitive_type "size_t") (identifier "param_3")) (, ",") (parameter_declaration "char param_4" (primitive_type "char") (identifier "param_4")) (, ",") (parameter_declaration "code *param_5" (type_identifier "code") (pointer_declarator "*param_5" (* "*") (identifier "param_5"))) () ")"))) (compound_statement "{\n  char cVar1;\n  char cVar2;\n  ushort uVar3;\n  int iVar4;\n  undefined4 uVar5;\n  void *__dest;\n  size_t sVar6;\n  int iVar7;\n  size_t sVar8;\n  undefined1 uVar9;\n  ushort local_28;\n  size_t local_24;\n  \n  if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }\n  iVar7 = 1000000000;\n  if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }\n  sVar6 = param_3;\n  local_24 = param_3;\n  if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }\n  *(size_t *)(param_1 + 0xc) = param_3;\n  *(ushort *)(param_1 + 8) = local_28;\n  if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }\nLAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }\n  return 0;\n}" ({ "{") (declaration "char cVar1;" (primitive_type "char") (identifier "cVar1") (; ";")) (declaration "char cVar2;" (primitive_type "char") (identifier "cVar2") (; ";")) (declaration "ushort uVar3;" (type_identifier "ushort") (identifier "uVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "undefined4 uVar5;" (type_identifier "undefined4") (identifier "uVar5") (; ";")) (declaration "void *__dest;" (primitive_type "void") (pointer_declarator "*__dest" (* "*") (identifier "__dest")) (; ";")) (declaration "size_t sVar6;" (primitive_type "size_t") (identifier "sVar6") (; ";")) (declaration "int iVar7;" (primitive_type "int") (identifier "iVar7") (; ";")) (declaration "size_t sVar8;" (primitive_type "size_t") (identifier "sVar8") (; ";")) (declaration "undefined1 uVar9;" (type_identifier "undefined1") (identifier "uVar9") (; ";")) (declaration "ushort local_28;" (type_identifier "ushort") (identifier "local_28") (; ";")) (declaration "size_t local_24;" (primitive_type "size_t") (identifier "local_24") (; ";")) (if_statement "if (param_2 == (char *)0x0) {\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }" (if "if") (parenthesized_expression "(param_2 == (char *)0x0)" (( "(") (binary_expression "param_2 == (char *)0x0" (identifier "param_2") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }\n    *(undefined2 *)(param_1 + 8) = 1;\n    return 0;\n  }" ({ "{") (if_statement "if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {\n      FUN_00024f00();\n      return 0;\n    }" (if "if") (parenthesized_expression "((*(ushort *)(param_1 + 8) & 0x2400) != 0)" (( "(") (binary_expression "(*(ushort *)(param_1 + 8) & 0x2400) != 0" (parenthesized_expression "(*(ushort *)(param_1 + 8) & 0x2400)" (( "(") (binary_expression "*(ushort *)(param_1 + 8) & 0x2400" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (& "&") (number_literal "0x2400")) () ")")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      FUN_00024f00();\n      return 0;\n    }" ({ "{") (expression_statement "FUN_00024f00();" (call_expression "FUN_00024f00()" (identifier "FUN_00024f00") (argument_list "()" (( "(") () ")"))) (; ";")) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "*(undefined2 *)(param_1 + 8) = 1;" (assignment_expression "*(undefined2 *)(param_1 + 8) = 1" (pointer_expression "*(undefined2 *)(param_1 + 8)" (* "*") (cast_expression "(undefined2 *)(param_1 + 8)" (( "(") (type_descriptor "undefined2 *" (type_identifier "undefined2") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (= "=") (number_literal "1")) (; ";")) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "iVar7 = 1000000000;" (assignment_expression "iVar7 = 1000000000" (identifier "iVar7") (= "=") (number_literal "1000000000")) (; ";")) (if_statement "if (*(int *)(param_1 + 0x20) != 0) {\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0x20) != 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x20) != 0" (pointer_expression "*(int *)(param_1 + 0x20)" (* "*") (cast_expression "(int *)(param_1 + 0x20)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x20)" (( "(") (binary_expression "param_1 + 0x20" (identifier "param_1") (+ "+") (number_literal "0x20")) () ")")))) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);\n  }" ({ "{") (expression_statement "iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);" (assignment_expression "iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68)" (identifier "iVar7") (= "=") (pointer_expression "*(int *)(*(int *)(param_1 + 0x20) + 0x68)" (* "*") (cast_expression "(int *)(*(int *)(param_1 + 0x20) + 0x68)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*(int *)(param_1 + 0x20) + 0x68)" (( "(") (binary_expression "*(int *)(param_1 + 0x20) + 0x68" (pointer_expression "*(int *)(param_1 + 0x20)" (* "*") (cast_expression "(int *)(param_1 + 0x20)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x20)" (( "(") (binary_expression "param_1 + 0x20" (identifier "param_1") (+ "+") (number_literal "0x20")) () ")")))) (+ "+") (number_literal "0x68")) () ")"))))) (; ";")) (} "}"))) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" (identifier "sVar6") (= "=") (identifier "param_3")) (; ";")) (expression_statement "local_24 = param_3;" (assignment_expression "local_24 = param_3" (identifier "local_24") (= "=") (identifier "param_3")) (; ";")) (if_statement "if (param_4 == '\0') {\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }\n  else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" (if "if") (parenthesized_expression "(param_4 == '\0')" (( "(") (binary_expression "param_4 == '\0'" (identifier "param_4") (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n    if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }\nLAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;\n    if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }\n  }" ({ "{") (if_statement "if ((int)param_3 < 0) {\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }\n    else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" (if "if") (parenthesized_expression "((int)param_3 < 0)" (( "(") (binary_expression "(int)param_3 < 0" (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3")) (< "<") (number_literal "0")) () ")")) (compound_statement "{\n      local_28 = 0x210;\nLAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }\n      if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }\n    }" ({ "{") (expression_statement "local_28 = 0x210;" (assignment_expression "local_28 = 0x210" (identifier "local_28") (= "=") (number_literal "0x210")) (; ";")) (labeled_statement "LAB_0004554a:\n      if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" (statement_identifier "LAB_0004554a") (: ":") (if_statement "if (iVar7 < 0) {\n        param_3 = 0;\n      }\n      else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" (if "if") (parenthesized_expression "(iVar7 < 0)" (( "(") (binary_expression "iVar7 < 0" (identifier "iVar7") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n        param_3 = 0;\n      }" ({ "{") (expression_statement "param_3 = 0;" (assignment_expression "param_3 = 0" (identifier "param_3") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" (else "else") (compound_statement "{\n        param_3 = 0;\n        sVar6 = param_3;\n        if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }\n      }" ({ "{") (expression_statement "param_3 = 0;" (assignment_expression "param_3 = 0" (identifier "param_3") (= "=") (number_literal "0")) (; ";")) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" (identifier "sVar6") (= "=") (identifier "param_3")) (; ";")) (if_statement "if (*param_2 != '\0' || param_2[1] != '\0') {\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }" (if "if") (parenthesized_expression "(*param_2 != '\0' || param_2[1] != '\0')" (( "(") (binary_expression "*param_2 != '\0' || param_2[1] != '\0'" (binary_expression "*param_2 != '\0'" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) (|| "||") (binary_expression "param_2[1] != '\0'" (subscript_expression "param_2[1]" (identifier "param_2") ([ "[") (number_literal "1") (] "]")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'")))) () ")")) (compound_statement "{\n          do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');\n        }" ({ "{") (do_statement "do {\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');" (do "do") (compound_statement "{\n            param_3 = sVar6 + 2;\n            if (iVar7 < (int)param_3) break;\n            iVar4 = sVar6 + 3;\n            sVar6 = param_3;\n          }" ({ "{") (expression_statement "param_3 = sVar6 + 2;" (assignment_expression "param_3 = sVar6 + 2" (identifier "param_3") (= "=") (binary_expression "sVar6 + 2" (identifier "sVar6") (+ "+") (number_literal "2"))) (; ";")) (if_statement "if (iVar7 < (int)param_3) break;" (if "if") (parenthesized_expression "(iVar7 < (int)param_3)" (( "(") (binary_expression "iVar7 < (int)param_3" (identifier "iVar7") (< "<") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3"))) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar4 = sVar6 + 3;" (assignment_expression "iVar4 = sVar6 + 3" (identifier "iVar4") (= "=") (binary_expression "sVar6 + 3" (identifier "sVar6") (+ "+") (number_literal "3"))) (; ";")) (expression_statement "sVar6 = param_3;" (assignment_expression "sVar6 = param_3" (identifier "sVar6") (= "=") (identifier "param_3")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(param_2[param_3] != '\0' || param_2[iVar4] != '\0')" (( "(") (binary_expression "param_2[param_3] != '\0' || param_2[iVar4] != '\0'" (binary_expression "param_2[param_3] != '\0'" (subscript_expression "param_2[param_3]" (identifier "param_2") ([ "[") (identifier "param_3") (] "]")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) (|| "||") (binary_expression "param_2[iVar4] != '\0'" (subscript_expression "param_2[iVar4]" (identifier "param_2") ([ "[") (identifier "iVar4") (] "]")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'")))) () ")")) (; ";")) (} "}"))) (} "}"))))) (if_statement "if (param_5 == (code *)0xffffffff) {\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" (if "if") (parenthesized_expression "(param_5 == (code *)0xffffffff)" (( "(") (binary_expression "param_5 == (code *)0xffffffff" (identifier "param_5") (== "==") (cast_expression "(code *)0xffffffff" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0xffffffff"))) () ")")) (compound_statement "{\n        iVar4 = 2;\n        goto LAB_00045582;\n      }" ({ "{") (expression_statement "iVar4 = 2;" (assignment_expression "iVar4 = 2" (identifier "iVar4") (= "=") (number_literal "2")) (; ";")) (goto_statement "goto LAB_00045582;" (goto "goto") (statement_identifier "LAB_00045582") (; ";")) (} "}"))) (} "}")) (else_clause "else {\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" (else "else") (compound_statement "{\n      local_28 = 0x10;\n      if (param_5 == (code *)0xffffffff) goto LAB_00045588;\n    }" ({ "{") (expression_statement "local_28 = 0x10;" (assignment_expression "local_28 = 0x10" (identifier "local_28") (= "=") (number_literal "0x10")) (; ";")) (if_statement "if (param_5 == (code *)0xffffffff) goto LAB_00045588;" (if "if") (parenthesized_expression "(param_5 == (code *)0xffffffff)" (( "(") (binary_expression "param_5 == (code *)0xffffffff" (identifier "param_5") (== "==") (cast_expression "(code *)0xffffffff" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0xffffffff"))) () ")")) (goto_statement "goto LAB_00045588;" (goto "goto") (statement_identifier "LAB_00045588") (; ";"))) (} "}")))) (labeled_statement "LAB_000453ae:\n    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;" (statement_identifier "LAB_000453ae") (: ":") (expression_statement "uVar3 = *(ushort *)(param_1 + 8) & 0x2400;" (assignment_expression "uVar3 = *(ushort *)(param_1 + 8) & 0x2400" (identifier "uVar3") (= "=") (binary_expression "*(ushort *)(param_1 + 8) & 0x2400" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (& "&") (number_literal "0x2400"))) (; ";"))) (if_statement "if (param_5 == FUN_00019850) {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }\n    else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" (if "if") (parenthesized_expression "(param_5 == FUN_00019850)" (( "(") (binary_expression "param_5 == FUN_00019850" (identifier "param_5") (== "==") (identifier "FUN_00019850")) () ")")) (compound_statement "{\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(char **)(param_1 + 0x14) = param_2;\n      uVar5 = (*DAT_001491b8)(param_2);\n      *(undefined4 *)(param_1 + 0x18) = uVar5;\n    }" ({ "{") (if_statement "if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }" (if "if") (parenthesized_expression "((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0))" (( "(") (binary_expression "(uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)" (parenthesized_expression "(uVar3 != 0)" (( "(") (binary_expression "uVar3 != 0" (identifier "uVar3") (!= "!=") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x18) != 0" (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")) () ")")))) (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n        FUN_00025180();\n      }" ({ "{") (expression_statement "FUN_00025180();" (call_expression "FUN_00025180()" (identifier "FUN_00025180") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (expression_statement "*(char **)(param_1 + 0x10) = param_2;" (assignment_expression "*(char **)(param_1 + 0x10) = param_2" (pointer_expression "*(char **)(param_1 + 0x10)" (* "*") (cast_expression "(char **)(param_1 + 0x10)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (= "=") (identifier "param_2")) (; ";")) (expression_statement "*(char **)(param_1 + 0x14) = param_2;" (assignment_expression "*(char **)(param_1 + 0x14) = param_2" (pointer_expression "*(char **)(param_1 + 0x14)" (* "*") (cast_expression "(char **)(param_1 + 0x14)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x14)" (( "(") (binary_expression "param_1 + 0x14" (identifier "param_1") (+ "+") (number_literal "0x14")) () ")")))) (= "=") (identifier "param_2")) (; ";")) (expression_statement "uVar5 = (*DAT_001491b8)(param_2);" (assignment_expression "uVar5 = (*DAT_001491b8)(param_2)" (identifier "uVar5") (= "=") (call_expression "(*DAT_001491b8)(param_2)" (parenthesized_expression "(*DAT_001491b8)" (( "(") (pointer_expression "*DAT_001491b8" (* "*") (identifier "DAT_001491b8")) () ")")) (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x18) = uVar5;" (assignment_expression "*(undefined4 *)(param_1 + 0x18) = uVar5" (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")) () ")")))) (= "=") (identifier "uVar5")) (; ";")) (} "}")) (else_clause "else {\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" (else "else") (compound_statement "{\n      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }\n      *(char **)(param_1 + 0x10) = param_2;\n      *(code **)(param_1 + 0x24) = param_5;\n      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;\n    }" ({ "{") (if_statement "if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {\n        FUN_00025180();\n      }" (if "if") (parenthesized_expression "((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0))" (( "(") (binary_expression "(uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)" (parenthesized_expression "(uVar3 != 0)" (( "(") (binary_expression "uVar3 != 0" (identifier "uVar3") (!= "!=") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x18) != 0" (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")) () ")")))) (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n        FUN_00025180();\n      }" ({ "{") (expression_statement "FUN_00025180();" (call_expression "FUN_00025180()" (identifier "FUN_00025180") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (expression_statement "*(char **)(param_1 + 0x10) = param_2;" (assignment_expression "*(char **)(param_1 + 0x10) = param_2" (pointer_expression "*(char **)(param_1 + 0x10)" (* "*") (cast_expression "(char **)(param_1 + 0x10)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (= "=") (identifier "param_2")) (; ";")) (expression_statement "*(code **)(param_1 + 0x24) = param_5;" (assignment_expression "*(code **)(param_1 + 0x24) = param_5" (pointer_expression "*(code **)(param_1 + 0x24)" (* "*") (cast_expression "(code **)(param_1 + 0x24)" (( "(") (type_descriptor "code **" (type_identifier "code") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x24)" (( "(") (binary_expression "param_1 + 0x24" (identifier "param_1") (+ "+") (number_literal "0x24")) () ")")))) (= "=") (identifier "param_5")) (; ";")) (expression_statement "local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;" (assignment_expression "local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" (identifier "local_28") (= "=") (binary_expression "local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" (identifier "local_28") (| "|") (binary_expression "(-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400" (parenthesized_expression "(-(ushort)(param_5 == (code *)0x0) & 0x400)" (( "(") (binary_expression "-(ushort)(param_5 == (code *)0x0) & 0x400" (unary_expression "-(ushort)(param_5 == (code *)0x0)" (- "-") (call_expression "(ushort)(param_5 == (code *)0x0)" (parenthesized_expression "(ushort)" (( "(") (identifier "ushort") () ")")) (argument_list "(param_5 == (code *)0x0)" (( "(") (binary_expression "param_5 == (code *)0x0" (identifier "param_5") (== "==") (cast_expression "(code *)0x0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")))) (& "&") (number_literal "0x400")) () ")")) (+ "+") (number_literal "0x400")))) (; ";")) (} "}")))) (} "}")) (else_clause "else {\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" (else "else") (compound_statement "{\n    local_28 = 2;\n    if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;\nLAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }\n    sVar8 = 0x20;\n    if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }\n    if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }\n    memcpy(__dest,param_2,sVar6);\n    param_3 = local_24;\n  }" ({ "{") (expression_statement "local_28 = 2;" (assignment_expression "local_28 = 2" (identifier "local_28") (= "=") (number_literal "2")) (; ";")) (if_statement "if ((int)param_3 < 0) {\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }\n    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" (if "if") (parenthesized_expression "((int)param_3 < 0)" (( "(") (binary_expression "(int)param_3 < 0" (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3")) (< "<") (number_literal "0")) () ")")) (compound_statement "{\n      if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }\n      param_3 = strlen(param_2);\n      if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }\n      if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }\n      local_28 = 0x202;\n      iVar4 = 1;\nLAB_00045582:\n      sVar6 = param_3 + iVar4;\n      local_24 = param_3;\n    }" ({ "{") (if_statement "if (param_4 != '\x01') {\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" (if "if") (parenthesized_expression "(param_4 != '\x01')" (( "(") (binary_expression "param_4 != '\x01'" (identifier "param_4") (!= "!=") (char_literal "'\x01'" (' "'") (escape_sequence "\x01") (' "'"))) () ")")) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_0004554a;\n      }" ({ "{") (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" (identifier "local_28") (= "=") (number_literal "0x202")) (; ";")) (goto_statement "goto LAB_0004554a;" (goto "goto") (statement_identifier "LAB_0004554a") (; ";")) (} "}"))) (expression_statement "param_3 = strlen(param_2);" (assignment_expression "param_3 = strlen(param_2)" (identifier "param_3") (= "=") (call_expression "strlen(param_2)" (identifier "strlen") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (if_statement "if (iVar7 < (int)param_3) {\n        param_3 = iVar7 + 1;\n      }" (if "if") (parenthesized_expression "(iVar7 < (int)param_3)" (( "(") (binary_expression "iVar7 < (int)param_3" (identifier "iVar7") (< "<") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3"))) () ")")) (compound_statement "{\n        param_3 = iVar7 + 1;\n      }" ({ "{") (expression_statement "param_3 = iVar7 + 1;" (assignment_expression "param_3 = iVar7 + 1" (identifier "param_3") (= "=") (binary_expression "iVar7 + 1" (identifier "iVar7") (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (if_statement "if (param_5 != (code *)0xffffffff) {\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" (if "if") (parenthesized_expression "(param_5 != (code *)0xffffffff)" (( "(") (binary_expression "param_5 != (code *)0xffffffff" (identifier "param_5") (!= "!=") (cast_expression "(code *)0xffffffff" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0xffffffff"))) () ")")) (compound_statement "{\n        local_28 = 0x202;\n        goto LAB_000453ae;\n      }" ({ "{") (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" (identifier "local_28") (= "=") (number_literal "0x202")) (; ";")) (goto_statement "goto LAB_000453ae;" (goto "goto") (statement_identifier "LAB_000453ae") (; ";")) (} "}"))) (expression_statement "local_28 = 0x202;" (assignment_expression "local_28 = 0x202" (identifier "local_28") (= "=") (number_literal "0x202")) (; ";")) (expression_statement "iVar4 = 1;" (assignment_expression "iVar4 = 1" (identifier "iVar4") (= "=") (number_literal "1")) (; ";")) (labeled_statement "LAB_00045582:\n      sVar6 = param_3 + iVar4;" (statement_identifier "LAB_00045582") (: ":") (expression_statement "sVar6 = param_3 + iVar4;" (assignment_expression "sVar6 = param_3 + iVar4" (identifier "sVar6") (= "=") (binary_expression "param_3 + iVar4" (identifier "param_3") (+ "+") (identifier "iVar4"))) (; ";"))) (expression_statement "local_24 = param_3;" (assignment_expression "local_24 = param_3" (identifier "local_24") (= "=") (identifier "param_3")) (; ";")) (} "}")) (else_clause "else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" (else "else") (if_statement "if (param_5 != (code *)0xffffffff) goto LAB_000453ae;" (if "if") (parenthesized_expression "(param_5 != (code *)0xffffffff)" (( "(") (binary_expression "param_5 != (code *)0xffffffff" (identifier "param_5") (!= "!=") (cast_expression "(code *)0xffffffff" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0xffffffff"))) () ")")) (goto_statement "goto LAB_000453ae;" (goto "goto") (statement_identifier "LAB_000453ae") (; ";"))))) (labeled_statement "LAB_00045588:\n    if (iVar7 < (int)local_24) {\n      return 0x12;\n    }" (statement_identifier "LAB_00045588") (: ":") (if_statement "if (iVar7 < (int)local_24) {\n      return 0x12;\n    }" (if "if") (parenthesized_expression "(iVar7 < (int)local_24)" (( "(") (binary_expression "iVar7 < (int)local_24" (identifier "iVar7") (< "<") (cast_expression "(int)local_24" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "local_24"))) () ")")) (compound_statement "{\n      return 0x12;\n    }" ({ "{") (return_statement "return 0x12;" (return "return") (number_literal "0x12") (; ";")) (} "}")))) (expression_statement "sVar8 = 0x20;" (assignment_expression "sVar8 = 0x20" (identifier "sVar8") (= "=") (number_literal "0x20")) (; ";")) (if_statement "if (0x1f < (int)sVar6) {\n      sVar8 = sVar6;\n    }" (if "if") (parenthesized_expression "(0x1f < (int)sVar6)" (( "(") (binary_expression "0x1f < (int)sVar6" (number_literal "0x1f") (< "<") (cast_expression "(int)sVar6" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "sVar6"))) () ")")) (compound_statement "{\n      sVar8 = sVar6;\n    }" ({ "{") (expression_statement "sVar8 = sVar6;" (assignment_expression "sVar8 = sVar6" (identifier "sVar8") (= "=") (identifier "sVar6")) (; ";")) (} "}"))) (if_statement "if (*(int *)(param_1 + 0x18) < (int)sVar8) {\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }\n    else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0x18) < (int)sVar8)" (( "(") (binary_expression "*(int *)(param_1 + 0x18) < (int)sVar8" (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")) () ")")))) (< "<") (cast_expression "(int)sVar8" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "sVar8"))) () ")")) (compound_statement "{\n      iVar4 = FUN_00044790();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      __dest = *(void **)(param_1 + 0x10);\n    }" ({ "{") (expression_statement "iVar4 = FUN_00044790();" (assignment_expression "iVar4 = FUN_00044790()" (identifier "iVar4") (= "=") (call_expression "FUN_00044790()" (identifier "FUN_00044790") (argument_list "()" (( "(") () ")")))) (; ";")) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" (if "if") (parenthesized_expression "(iVar4 != 0)" (( "(") (binary_expression "iVar4 != 0" (identifier "iVar4") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        return 7;\n      }" ({ "{") (return_statement "return 7;" (return "return") (number_literal "7") (; ";")) (} "}"))) (expression_statement "__dest = *(void **)(param_1 + 0x10);" (assignment_expression "__dest = *(void **)(param_1 + 0x10)" (identifier "__dest") (= "=") (pointer_expression "*(void **)(param_1 + 0x10)" (* "*") (cast_expression "(void **)(param_1 + 0x10)" (( "(") (type_descriptor "void **" (primitive_type "void") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")"))))) (; ";")) (} "}")) (else_clause "else {\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" (else "else") (compound_statement "{\n      __dest = *(void **)(param_1 + 0x14);\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;\n      *(void **)(param_1 + 0x10) = __dest;\n    }" ({ "{") (expression_statement "__dest = *(void **)(param_1 + 0x14);" (assignment_expression "__dest = *(void **)(param_1 + 0x14)" (identifier "__dest") (= "=") (pointer_expression "*(void **)(param_1 + 0x14)" (* "*") (cast_expression "(void **)(param_1 + 0x14)" (( "(") (type_descriptor "void **" (primitive_type "void") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x14)" (( "(") (binary_expression "param_1 + 0x14" (identifier "param_1") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (expression_statement "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;" (assignment_expression "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (= "=") (binary_expression "*(ushort *)(param_1 + 8) & 0xd" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (& "&") (number_literal "0xd"))) (; ";")) (expression_statement "*(void **)(param_1 + 0x10) = __dest;" (assignment_expression "*(void **)(param_1 + 0x10) = __dest" (pointer_expression "*(void **)(param_1 + 0x10)" (* "*") (cast_expression "(void **)(param_1 + 0x10)" (( "(") (type_descriptor "void **" (primitive_type "void") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (= "=") (identifier "__dest")) (; ";")) (} "}")))) (expression_statement "memcpy(__dest,param_2,sVar6);" (call_expression "memcpy(__dest,param_2,sVar6)" (identifier "memcpy") (argument_list "(__dest,param_2,sVar6)" (( "(") (identifier "__dest") (, ",") (identifier "param_2") (, ",") (identifier "sVar6") () ")"))) (; ";")) (expression_statement "param_3 = local_24;" (assignment_expression "param_3 = local_24" (identifier "param_3") (= "=") (identifier "local_24")) (; ";")) (} "}")))) (expression_statement "*(size_t *)(param_1 + 0xc) = param_3;" (assignment_expression "*(size_t *)(param_1 + 0xc) = param_3" (pointer_expression "*(size_t *)(param_1 + 0xc)" (* "*") (cast_expression "(size_t *)(param_1 + 0xc)" (( "(") (type_descriptor "size_t *" (primitive_type "size_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (= "=") (identifier "param_3")) (; ";")) (expression_statement "*(ushort *)(param_1 + 8) = local_28;" (assignment_expression "*(ushort *)(param_1 + 8) = local_28" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (= "=") (identifier "local_28")) (; ";")) (if_statement "if (param_4 == '\0') {\n    *(undefined1 *)(param_1 + 10) = 1;\n  }\n  else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" (if "if") (parenthesized_expression "(param_4 == '\0')" (( "(") (binary_expression "param_4 == '\0'" (identifier "param_4") (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n    *(undefined1 *)(param_1 + 10) = 1;\n  }" ({ "{") (expression_statement "*(undefined1 *)(param_1 + 10) = 1;" (assignment_expression "*(undefined1 *)(param_1 + 10) = 1" (pointer_expression "*(undefined1 *)(param_1 + 10)" (* "*") (cast_expression "(undefined1 *)(param_1 + 10)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 10)" (( "(") (binary_expression "param_1 + 10" (identifier "param_1") (+ "+") (number_literal "10")) () ")")))) (= "=") (number_literal "1")) (; ";")) (} "}")) (else_clause "else {\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" (else "else") (compound_statement "{\n    *(char *)(param_1 + 10) = param_4;\n    if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }\n  }" ({ "{") (expression_statement "*(char *)(param_1 + 10) = param_4;" (assignment_expression "*(char *)(param_1 + 10) = param_4" (pointer_expression "*(char *)(param_1 + 10)" (* "*") (cast_expression "(char *)(param_1 + 10)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 10)" (( "(") (binary_expression "param_1 + 10" (identifier "param_1") (+ "+") (number_literal "10")) () ")")))) (= "=") (identifier "param_4")) (; ";")) (if_statement "if ((1 < (int)param_3) && (param_4 != '\x01')) {\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }" (if "if") (parenthesized_expression "((1 < (int)param_3) && (param_4 != '\x01'))" (( "(") (binary_expression "(1 < (int)param_3) && (param_4 != '\x01')" (parenthesized_expression "(1 < (int)param_3)" (( "(") (binary_expression "1 < (int)param_3" (number_literal "1") (< "<") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3"))) () ")")) (&& "&&") (parenthesized_expression "(param_4 != '\x01')" (( "(") (binary_expression "param_4 != '\x01'" (identifier "param_4") (!= "!=") (char_literal "'\x01'" (' "'") (escape_sequence "\x01") (' "'"))) () ")"))) () ")")) (compound_statement "{\n      cVar1 = **(char **)(param_1 + 0x10);\n      cVar2 = (*(char **)(param_1 + 0x10))[1];\n      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }\n      iVar4 = FUN_000452f0();\n      if (iVar4 != 0) {\n        return 7;\n      }\n      sVar6 = *(int *)(param_1 + 0xc) - 2;\n      *(size_t *)(param_1 + 0xc) = sVar6;\n      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;\n      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;\n      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;\n      *(undefined1 *)(param_1 + 10) = uVar9;\n    }" ({ "{") (expression_statement "cVar1 = **(char **)(param_1 + 0x10);" (assignment_expression "cVar1 = **(char **)(param_1 + 0x10)" (identifier "cVar1") (= "=") (pointer_expression "**(char **)(param_1 + 0x10)" (* "*") (pointer_expression "*(char **)(param_1 + 0x10)" (* "*") (cast_expression "(char **)(param_1 + 0x10)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))))) (; ";")) (expression_statement "cVar2 = (*(char **)(param_1 + 0x10))[1];" (assignment_expression "cVar2 = (*(char **)(param_1 + 0x10))[1]" (identifier "cVar2") (= "=") (subscript_expression "(*(char **)(param_1 + 0x10))[1]" (parenthesized_expression "(*(char **)(param_1 + 0x10))" (( "(") (pointer_expression "*(char **)(param_1 + 0x10)" (* "*") (cast_expression "(char **)(param_1 + 0x10)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) () ")")) ([ "[") (number_literal "1") (] "]"))) (; ";")) (if_statement "if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }" (if "if") (parenthesized_expression "((cVar1 != -2) || (uVar9 = 3, cVar2 != -1))" (( "(") (binary_expression "(cVar1 != -2) || (uVar9 = 3, cVar2 != -1)" (parenthesized_expression "(cVar1 != -2)" (( "(") (binary_expression "cVar1 != -2" (identifier "cVar1") (!= "!=") (number_literal "-2")) () ")")) (|| "||") (parenthesized_expression "(uVar9 = 3, cVar2 != -1)" (( "(") (comma_expression "uVar9 = 3, cVar2 != -1" (assignment_expression "uVar9 = 3" (identifier "uVar9") (= "=") (number_literal "3")) (, ",") (binary_expression "cVar2 != -1" (identifier "cVar2") (!= "!=") (number_literal "-1"))) () ")"))) () ")")) (compound_statement "{\n        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;\n        uVar9 = 2;\n      }" ({ "{") (if_statement "if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;" (if "if") (parenthesized_expression "((cVar1 != -1) || (cVar2 != -2))" (( "(") (binary_expression "(cVar1 != -1) || (cVar2 != -2)" (parenthesized_expression "(cVar1 != -1)" (( "(") (binary_expression "cVar1 != -1" (identifier "cVar1") (!= "!=") (number_literal "-1")) () ")")) (|| "||") (parenthesized_expression "(cVar2 != -2)" (( "(") (binary_expression "cVar2 != -2" (identifier "cVar2") (!= "!=") (number_literal "-2")) () ")"))) () ")")) (goto_statement "goto LAB_00045408;" (goto "goto") (statement_identifier "LAB_00045408") (; ";"))) (expression_statement "uVar9 = 2;" (assignment_expression "uVar9 = 2" (identifier "uVar9") (= "=") (number_literal "2")) (; ";")) (} "}"))) (expression_statement "iVar4 = FUN_000452f0();" (assignment_expression "iVar4 = FUN_000452f0()" (identifier "iVar4") (= "=") (call_expression "FUN_000452f0()" (identifier "FUN_000452f0") (argument_list "()" (( "(") () ")")))) (; ";")) (if_statement "if (iVar4 != 0) {\n        return 7;\n      }" (if "if") (parenthesized_expression "(iVar4 != 0)" (( "(") (binary_expression "iVar4 != 0" (identifier "iVar4") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        return 7;\n      }" ({ "{") (return_statement "return 7;" (return "return") (number_literal "7") (; ";")) (} "}"))) (expression_statement "sVar6 = *(int *)(param_1 + 0xc) - 2;" (assignment_expression "sVar6 = *(int *)(param_1 + 0xc) - 2" (identifier "sVar6") (= "=") (binary_expression "*(int *)(param_1 + 0xc) - 2" (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")) () ")")))) (- "-") (number_literal "2"))) (; ";")) (expression_statement "*(size_t *)(param_1 + 0xc) = sVar6;" (assignment_expression "*(size_t *)(param_1 + 0xc) = sVar6" (pointer_expression "*(size_t *)(param_1 + 0xc)" (* "*") (cast_expression "(size_t *)(param_1 + 0xc)" (( "(") (type_descriptor "size_t *" (primitive_type "size_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (= "=") (identifier "sVar6")) (; ";")) (expression_statement "memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);" (call_expression "memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6)" (identifier "memmove") (argument_list "(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6)" (( "(") (pointer_expression "*(void **)(param_1 + 0x10)" (* "*") (cast_expression "(void **)(param_1 + 0x10)" (( "(") (type_descriptor "void **" (primitive_type "void") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (, ",") (cast_expression "(void *)((int)*(void **)(param_1 + 0x10) + 2)" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)*(void **)(param_1 + 0x10) + 2)" (( "(") (binary_expression "(int)*(void **)(param_1 + 0x10) + 2" (cast_expression "(int)*(void **)(param_1 + 0x10)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (pointer_expression "*(void **)(param_1 + 0x10)" (* "*") (cast_expression "(void **)(param_1 + 0x10)" (( "(") (type_descriptor "void **" (primitive_type "void") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")"))))) (+ "+") (number_literal "2")) () ")"))) (, ",") (identifier "sVar6") () ")"))) (; ";")) (expression_statement "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;" (assignment_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0" (pointer_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" (* "*") (cast_expression "(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc))" (( "(") (binary_expression "*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)" (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")) () ")")))) (+ "+") (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")) () ")"))))) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;" (assignment_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0" (pointer_expression "*(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" (* "*") (cast_expression "(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc))" (( "(") (binary_expression "*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)" (binary_expression "*(int *)(param_1 + 0x10) + 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")) () ")")))) (+ "+") (number_literal "1")) (+ "+") (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")) () ")"))))) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;" (assignment_expression "*(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (= "=") (binary_expression "*(ushort *)(param_1 + 8) | 0x200" (pointer_expression "*(ushort *)(param_1 + 8)" (* "*") (cast_expression "(ushort *)(param_1 + 8)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) (| "|") (number_literal "0x200"))) (; ";")) (expression_statement "*(undefined1 *)(param_1 + 10) = uVar9;" (assignment_expression "*(undefined1 *)(param_1 + 10) = uVar9" (pointer_expression "*(undefined1 *)(param_1 + 10)" (* "*") (cast_expression "(undefined1 *)(param_1 + 10)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 10)" (( "(") (binary_expression "param_1 + 10" (identifier "param_1") (+ "+") (number_literal "10")) () ")")))) (= "=") (identifier "uVar9")) (; ";")) (} "}"))) (} "}")))) (labeled_statement "LAB_00045408:\n  if (iVar7 < (int)param_3) {\n    return 0x12;\n  }" (statement_identifier "LAB_00045408") (: ":") (if_statement "if (iVar7 < (int)param_3) {\n    return 0x12;\n  }" (if "if") (parenthesized_expression "(iVar7 < (int)param_3)" (( "(") (binary_expression "iVar7 < (int)param_3" (identifier "iVar7") (< "<") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3"))) () ")")) (compound_statement "{\n    return 0x12;\n  }" ({ "{") (return_statement "return 0x12;" (return "return") (number_literal "0x12") (; ";")) (} "}")))) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}")))

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

int __regparm3 function_1(type_1 *pMem,char *var_1,int var_4,type_2 var_3,type_3 *var_7)

{
  char var_16;
  char var_17;
  type_4 var_9;
  int var_13;
  char *__dest;
  size_t var_6;
  int var_5;
  size_t szNew;
  type_2 uVar7;
  type_4 var_11;
  size_t local_24;
  
  if (var_1 == (char *)0x0) {
    if ((pMem->flags & 0x2400) != 0) {
      var_2(pMem);
      return 0;
    }
    pMem->flags = 1;
    return 0;
  }
  var_5 = 1000000000;
  if (pMem->db != (type_5 *)0x0) {
    var_5 = pMem->db->aLimit[0];
  }
  var_6 = var_4;
  local_24 = var_4;
  if (var_3 == '\0') {
    if (var_4 < 0) {
      var_11 = 0x210;
LAB_0004554a:
      if (var_5 < 0) {
        var_4 = 0;
      }
      else {
        var_4 = 0;
        var_6 = var_4;
        if (*var_1 != '\0' || var_1[1] != '\0') {
          do {
            var_4 = var_6 + 2;
            if (var_5 < var_4) break;
            var_13 = var_6 + 3;
            var_6 = var_4;
          } while (var_1[var_4] != '\0' || var_1[var_13] != '\0');
        }
      }
      if (var_7 == (type_3 *)&DAT_ffffffff) {
        var_13 = 2;
        goto LAB_00045582;
      }
    }
    else {
      var_11 = 0x10;
      if (var_7 == (type_3 *)&DAT_ffffffff) goto LAB_00045588;
    }
LAB_000453ae:
    var_9 = pMem->flags & 0x2400;
    if (var_7 == var_8) {
      if ((var_9 != 0) || (pMem->szMalloc != 0)) {
        var_10(pMem);
      }
      pMem->var_1 = var_1;
      pMem->zMalloc = var_1;
      var_13 = (*sqlite3Config.m.xSize)(var_1);
      pMem->szMalloc = var_13;
    }
    else {
      if ((var_9 != 0) || (pMem->szMalloc != 0)) {
        var_10(pMem);
      }
      pMem->var_1 = var_1;
      pMem->var_7 = var_7;
      var_11 = var_11 | (-(type_4)(var_7 == (type_3 *)0x0) & 0x400) + 0x400;
    }
  }
  else {
    var_11 = 2;
    if (var_4 < 0) {
      if (var_3 != '\x01') {
        var_11 = 0x202;
        goto LAB_0004554a;
      }
      var_4 = var_12(var_1);
      if (var_5 < var_4) {
        var_4 = var_5 + 1;
      }
      if (var_7 != (type_3 *)&DAT_ffffffff) {
        var_11 = 0x202;
        goto LAB_000453ae;
      }
      var_11 = 0x202;
      var_13 = 1;
LAB_00045582:
      var_6 = var_4 + var_13;
      local_24 = var_4;
    }
    else if (var_7 != (type_3 *)&DAT_ffffffff) goto LAB_000453ae;
LAB_00045588:
    if (var_5 < (int)local_24) {
      return 0x12;
    }
    szNew = 0x20;
    if (0x1f < (int)var_6) {
      szNew = var_6;
    }
    if (pMem->szMalloc < (int)szNew) {
      var_13 = var_14(pMem,szNew);
      if (var_13 != 0) {
        return 7;
      }
      __dest = pMem->var_1;
    }
    else {
      __dest = pMem->zMalloc;
      pMem->flags = pMem->flags & 0xd;
      pMem->var_1 = __dest;
    }
    var_15(__dest,var_1,var_6);
    var_4 = local_24;
  }
  pMem->var_4 = var_4;
  pMem->flags = var_11;
  if (var_3 == '\0') {
    pMem->var_3 = '\x01';
  }
  else {
    pMem->var_3 = var_3;
    if ((1 < var_4) && (var_3 != '\x01')) {
      var_16 = *pMem->var_1;
      var_17 = pMem->var_1[1];
      if ((var_16 != -2) || (uVar7 = '\x03', var_17 != -1)) {
        if ((var_16 != -1) || (var_17 != -2)) goto LAB_00045408;
        uVar7 = '\x02';
      }
      var_13 = var_18(pMem);
      if (var_13 != 0) {
        return 7;
      }
      var_6 = pMem->var_4 - 2;
      pMem->var_4 = var_6;
      var_19(pMem->var_1,pMem->var_1 + 2,var_6);
      pMem->var_1[pMem->var_4] = '\0';
      pMem->var_1[pMem->var_4 + 1] = '\0';
      pMem->flags = pMem->flags | 0x200;
      pMem->var_3 = uVar7;
    }
  }
LAB_00045408:
  if (var_5 < var_4) {
    return 0x12;
  }
  return 0;
}


(translation_unit (function_definition type: (type_identifier) (ERROR (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_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: (number_literal))))) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (return_statement (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: (identifier) right: (number_literal))))) right: (number_literal))) (return_statement (number_literal)))) (expression_statement (assignment_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: (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: (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))))))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (labeled_statement label: (statement_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))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (escape_sequence))) right: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) 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: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) consequence: (break_statement)) (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: (binary_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (char_literal (escape_sequence))) right: (binary_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (char_literal (escape_sequence)))))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (goto_statement label: (statement_identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (goto_statement label: (statement_identifier)))))) (labeled_statement label: (statement_identifier) (expression_statement (assignment_expression left: (identifier) right: (binary_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: (number_literal))))) right: (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (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: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator 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 declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (identifier))) arguments: (argument_list (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: (number_literal))))) right: (identifier)))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (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: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator 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: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (binary_expression left: (parenthesized_expression (binary_expression left: (unary_expression argument: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))))) right: (number_literal))) 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: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (goto_statement label: (statement_identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (goto_statement label: (statement_identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (labeled_statement label: (statement_identifier) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) alternative: (else_clause (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (goto_statement label: (statement_identifier))))) (labeled_statement label: (statement_identifier) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) consequence: (compound_statement (return_statement (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (number_literal) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) 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: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator 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: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (binary_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: (number_literal))))) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier)))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) 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: (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))))) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))) consequence: (compound_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: (identifier) right: (number_literal))))) 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: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (number_literal) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) right: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) index: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (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)))) (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 (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) right: (number_literal)))) (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: (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: (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))) (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: (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)) 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))))))))) right: (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: (identifier) right: (number_literal))))) right: (binary_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: (number_literal))))) right: (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: (identifier) right: (number_literal))))) right: (identifier)))))))) (labeled_statement label: (statement_identifier) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) consequence: (compound_statement (return_statement (number_literal))))) (return_statement (number_literal)))))

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

undefined4 __regparm3
MASKED(int param_1,char *param_2,size_t param_3,char param_4,code *param_5)

{
  char cVar1;
  char cVar2;
  ushort uVar3;
  int iVar4;
  undefined4 uVar5;
  void *__dest;
  size_t sVar6;
  int iVar7;
  size_t sVar8;
  undefined1 uVar9;
  ushort local_28;
  size_t local_24;
  
  if (param_2 == (char *)0x0) {
    if ((*(ushort *)(param_1 + 8) & 0x2400) != 0) {
      FUN_00024f00();
      return 0;
    }
    *(undefined2 *)(param_1 + 8) = 1;
    return 0;
  }
  iVar7 = 1000000000;
  if (*(int *)(param_1 + 0x20) != 0) {
    iVar7 = *(int *)(*(int *)(param_1 + 0x20) + 0x68);
  }
  sVar6 = param_3;
  local_24 = param_3;
  if (param_4 == '\0') {
    if ((int)param_3 < 0) {
      local_28 = 0x210;
LAB_0004554a:
      if (iVar7 < 0) {
        param_3 = 0;
      }
      else {
        param_3 = 0;
        sVar6 = param_3;
        if (*param_2 != '\0' || param_2[1] != '\0') {
          do {
            param_3 = sVar6 + 2;
            if (iVar7 < (int)param_3) break;
            iVar4 = sVar6 + 3;
            sVar6 = param_3;
          } while (param_2[param_3] != '\0' || param_2[iVar4] != '\0');
        }
      }
      if (param_5 == (code *)0xffffffff) {
        iVar4 = 2;
        goto LAB_00045582;
      }
    }
    else {
      local_28 = 0x10;
      if (param_5 == (code *)0xffffffff) goto LAB_00045588;
    }
LAB_000453ae:
    uVar3 = *(ushort *)(param_1 + 8) & 0x2400;
    if (param_5 == FUN_00019850) {
      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {
        FUN_00025180();
      }
      *(char **)(param_1 + 0x10) = param_2;
      *(char **)(param_1 + 0x14) = param_2;
      uVar5 = (*DAT_001491b8)(param_2);
      *(undefined4 *)(param_1 + 0x18) = uVar5;
    }
    else {
      if ((uVar3 != 0) || (*(int *)(param_1 + 0x18) != 0)) {
        FUN_00025180();
      }
      *(char **)(param_1 + 0x10) = param_2;
      *(code **)(param_1 + 0x24) = param_5;
      local_28 = local_28 | (-(ushort)(param_5 == (code *)0x0) & 0x400) + 0x400;
    }
  }
  else {
    local_28 = 2;
    if ((int)param_3 < 0) {
      if (param_4 != '\x01') {
        local_28 = 0x202;
        goto LAB_0004554a;
      }
      param_3 = strlen(param_2);
      if (iVar7 < (int)param_3) {
        param_3 = iVar7 + 1;
      }
      if (param_5 != (code *)0xffffffff) {
        local_28 = 0x202;
        goto LAB_000453ae;
      }
      local_28 = 0x202;
      iVar4 = 1;
LAB_00045582:
      sVar6 = param_3 + iVar4;
      local_24 = param_3;
    }
    else if (param_5 != (code *)0xffffffff) goto LAB_000453ae;
LAB_00045588:
    if (iVar7 < (int)local_24) {
      return 0x12;
    }
    sVar8 = 0x20;
    if (0x1f < (int)sVar6) {
      sVar8 = sVar6;
    }
    if (*(int *)(param_1 + 0x18) < (int)sVar8) {
      iVar4 = FUN_00044790();
      if (iVar4 != 0) {
        return 7;
      }
      __dest = *(void **)(param_1 + 0x10);
    }
    else {
      __dest = *(void **)(param_1 + 0x14);
      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) & 0xd;
      *(void **)(param_1 + 0x10) = __dest;
    }
    memcpy(__dest,param_2,sVar6);
    param_3 = local_24;
  }
  *(size_t *)(param_1 + 0xc) = param_3;
  *(ushort *)(param_1 + 8) = local_28;
  if (param_4 == '\0') {
    *(undefined1 *)(param_1 + 10) = 1;
  }
  else {
    *(char *)(param_1 + 10) = param_4;
    if ((1 < (int)param_3) && (param_4 != '\x01')) {
      cVar1 = **(char **)(param_1 + 0x10);
      cVar2 = (*(char **)(param_1 + 0x10))[1];
      if ((cVar1 != -2) || (uVar9 = 3, cVar2 != -1)) {
        if ((cVar1 != -1) || (cVar2 != -2)) goto LAB_00045408;
        uVar9 = 2;
      }
      iVar4 = FUN_000452f0();
      if (iVar4 != 0) {
        return 7;
      }
      sVar6 = *(int *)(param_1 + 0xc) - 2;
      *(size_t *)(param_1 + 0xc) = sVar6;
      memmove(*(void **)(param_1 + 0x10),(void *)((int)*(void **)(param_1 + 0x10) + 2),sVar6);
      *(undefined1 *)(*(int *)(param_1 + 0x10) + *(int *)(param_1 + 0xc)) = 0;
      *(undefined1 *)(*(int *)(param_1 + 0x10) + 1 + *(int *)(param_1 + 0xc)) = 0;
      *(ushort *)(param_1 + 8) = *(ushort *)(param_1 + 8) | 0x200;
      *(undefined1 *)(param_1 + 10) = uVar9;
    }
  }
LAB_00045408:
  if (iVar7 < (int)param_3) {
    return 0x12;
  }
  return 0;
}

