
CollSeq * findCollSeqEntry(sqlite3 *db,char *zName,int create)

{
  HashElem *pHVar1;
  uint uVar2;
  CollSeq *data;
  char *pKey;
  void *p;
  CollSeq *pCVar3;
  int iVar4;
  code *pcVar5;
  undefined1 *puVar6;
  undefined4 in_stack_ffffffd4;
  
  puVar6 = &_gp;
  pHVar1 = findElementWithHash(&db->aCollSeq,zName,(uint *)0x0);
  pCVar3 = (CollSeq *)pHVar1->data;
  if ((pCVar3 == (CollSeq *)0x0) && (create != 0)) {
    if (zName == (char *)0x0) {
      iVar4 = 1;
    }
    else {
      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);
      iVar4 = (uVar2 & 0x3fffffff) + 1;
    }
    data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));
    if (data != (CollSeq *)0x0) {
      pCVar3 = data + 3;
      pcVar5 = *(code **)(puVar6 + -0x7b80);
      data->zName = (char *)pCVar3;
      data[1].zName = (char *)pCVar3;
      data->enc = '\x01';
      data[2].zName = (char *)pCVar3;
      data[1].enc = '\x02';
      data[2].enc = '\x03';
      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);
      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);
      pCVar3 = data;
      if (p != (void *)0x0) {
        uVar2._0_1_ = db->temp_store;
        uVar2._1_1_ = db->mallocFailed;
        uVar2._2_1_ = db->bBenignMalloc;
        uVar2._3_1_ = db->dfltLockMode;
        if ((uVar2 & 0xffff00) == 0) {
          sqlite3OomFault(db);
        }
                    /* WARNING: Subroutine does not return */
        sqlite3DbFreeNN(db,p);
      }
    }
  }
  return pCVar3;
}



int * FUN_00030820(int param_1,int param_2,int param_3)

{
  undefined *puVar1;
  int iVar2;
  uint uVar3;
  int *piVar4;
  undefined4 uVar5;
  int *piVar6;
  int *piVar7;
  
  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);
  piVar6 = *(int **)(iVar2 + 8);
  piVar7 = piVar6;
  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {
    if (param_2 == 0) {
      iVar2 = 1;
    }
    else {
      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);
      iVar2 = (uVar3 & 0x3fffffff) + 1;
    }
    piVar4 = (int *)FUN_0002d5c0(param_1);
    puVar1 = PTR_memcpy_0015ba30;
    if (piVar4 != (int *)0x0) {
      piVar7 = piVar4 + 0xf;
      *piVar4 = (int)piVar7;
      piVar4[5] = (int)piVar7;
      *(undefined1 *)(piVar4 + 1) = 1;
      piVar4[10] = (int)piVar7;
      *(undefined1 *)(piVar4 + 6) = 2;
      *(undefined1 *)(piVar4 + 0xb) = 3;
      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);
      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);
      piVar7 = piVar4;
      if (iVar2 != 0) {
        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {
          FUN_0002d4c8(param_1);
        }
        FUN_0002a924(param_1,iVar2);
        piVar7 = piVar6;
      }
    }
  }
  return piVar7;
}


lui gp,0x13
addiu gp,gp,0x2d90
addu gp,gp,t9
addiu sp,sp,-0x40
lw t9,-0x7f54(gp)
or t4,a2,zero
or a2,zero,zero
sw s2,0x2c(sp)
addiu s2,a0,0x184
addiu t9,t9,-0x289c
sw gp,0x10(sp)
sw s1,0x28(sp)
or s1,a0,zero
sw s0,0x24(sp)
or a0,s2,zero
sw ra,0x3c(sp)
sw s5,0x38(sp)
sw s4,0x34(sp)
bal 0x0001d764
_sw s3,0x30(sp)
lw s0,0x8(v0)
beq s0,zero,0x000308a4
_lw gp,0x10(sp)
lw ra,0x3c(sp)
or v0,s0,zero
lw s5,0x38(sp)
lw s4,0x34(sp)
lw s3,0x30(sp)
lw s2,0x2c(sp)
lw s1,0x28(sp)
lw s0,0x24(sp)
jr ra
_addiu sp,sp,0x40
beq t4,zero,0x00030880
_lw ra,0x3c(sp)
beq a1,zero,0x000309a8
_or s3,a1,zero
lw t9,-0x7bec(gp)
jalr t9
_or a0,a1,zero
ext v0,v0,0x0,0x1e
lw gp,0x10(sp)
addiu s5,v0,0x1
addiu a3,v0,0x3d
lw t9,-0x7ed8(gp)
or a2,zero,zero
addiu t9,t9,-0x2a40
bal 0x0002d5c0
_or a0,s1,zero
lw gp,0x10(sp)
beq v0,zero,0x0003087c
_or s4,v0,zero
addiu v1,v0,0x3c
lw t9,-0x7b80(gp)
or a2,s5,zero
sw v1,0x0(v0)
li v0,0x1
or a0,v1,zero
sw v1,0x14(s4)
sb v0,0x4(s4)
li v0,0x2
or a1,s3,zero
sw v1,0x28(s4)
sb v0,0x18(s4)
li v0,0x3
jalr t9
_sb v0,0x2c(s4)
or a2,s4,zero
lw gp,0x10(sp)
or a1,v0,zero
lw t9,-0x7ed8(gp)
addiu t9,t9,0x47c
bal 0x0003047c
_or a0,s2,zero
beq v0,zero,0x000309a0
_lw gp,0x10(sp)
lw v1,0x50(s1)
lui a0,0xff
ori a0,a0,0xff00
and v1,v1,a0
bne v1,zero,0x00030988
_lw t9,-0x7ed8(gp)
lw t9,-0x7ed8(gp)
or a0,s1,zero
addiu t9,t9,-0x2b38
bal 0x0002d4c8
_sw v0,0x1c(sp)
lw gp,0x10(sp)
lw v0,0x1c(sp)
lw t9,-0x7ed8(gp)
or a1,v0,zero
addiu t9,t9,-0x56dc
bal 0x0002a924
_or a0,s1,zero
b 0x00030880
_lw ra,0x3c(sp)
b 0x0003087c
_or s0,s4,zero
li a3,0x3d
b 0x000308d0
_li s5,0x1
(translation_unit "int * FUN_00030820(int param_1,int param_2,int param_3)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}\n\n" (function_definition "int * FUN_00030820(int param_1,int param_2,int param_3)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}" primitive_type (pointer_declarator "* FUN_00030820(int param_1,int param_2,int param_3)" * (function_declarator "FUN_00030820(int param_1,int param_2,int param_3)" identifier (parameter_list "(int param_1,int param_2,int param_3)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "int param_3" primitive_type identifier) )))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "undefined4 uVar5;" type_identifier identifier ;) (declaration "int *piVar6;" primitive_type (pointer_declarator "*piVar6" * identifier) ;) (declaration "int *piVar7;" primitive_type (pointer_declarator "*piVar7" * identifier) ;) (expression_statement "iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);" (assignment_expression "iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0)" identifier = (call_expression "FUN_0001d764(param_1 + 0x184,param_2,0)" identifier (argument_list "(param_1 + 0x184,param_2,0)" ( (binary_expression "param_1 + 0x184" identifier + number_literal) , identifier , number_literal )))) ;) (expression_statement "piVar6 = *(int **)(iVar2 + 8);" (assignment_expression "piVar6 = *(int **)(iVar2 + 8)" identifier = (pointer_expression "*(int **)(iVar2 + 8)" * (cast_expression "(int **)(iVar2 + 8)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(iVar2 + 8)" ( (binary_expression "iVar2 + 8" identifier + number_literal) ))))) ;) (expression_statement "piVar7 = piVar6;" (assignment_expression "piVar7 = piVar6" identifier = identifier) ;) (if_statement "if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }" if (parenthesized_expression "((piVar6 == (int *)0x0) && (param_3 != 0))" ( (binary_expression "(piVar6 == (int *)0x0) && (param_3 != 0)" (parenthesized_expression "(piVar6 == (int *)0x0)" ( (binary_expression "piVar6 == (int *)0x0" identifier == (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(param_3 != 0)" ( (binary_expression "param_3 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }" { (if_statement "if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar2 = 1;\n    }" { (expression_statement "iVar2 = 1;" (assignment_expression "iVar2 = 1" identifier = number_literal) ;) }) (else_clause "else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" else (compound_statement "{\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" { (expression_statement "uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);" (assignment_expression "uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2)" identifier = (call_expression "(*(code *)PTR_strlen_0015b9c4)(param_2)" (parenthesized_expression "(*(code *)PTR_strlen_0015b9c4)" ( (pointer_expression "*(code *)PTR_strlen_0015b9c4" * (cast_expression "(code *)PTR_strlen_0015b9c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "iVar2 = (uVar3 & 0x3fffffff) + 1;" (assignment_expression "iVar2 = (uVar3 & 0x3fffffff) + 1" identifier = (binary_expression "(uVar3 & 0x3fffffff) + 1" (parenthesized_expression "(uVar3 & 0x3fffffff)" ( (binary_expression "uVar3 & 0x3fffffff" identifier & number_literal) )) + number_literal)) ;) }))) (expression_statement "piVar4 = (int *)FUN_0002d5c0(param_1);" (assignment_expression "piVar4 = (int *)FUN_0002d5c0(param_1)" identifier = (cast_expression "(int *)FUN_0002d5c0(param_1)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0002d5c0(param_1)" identifier (argument_list "(param_1)" ( identifier ))))) ;) (expression_statement "puVar1 = PTR_memcpy_0015ba30;" (assignment_expression "puVar1 = PTR_memcpy_0015ba30" identifier = identifier) ;) (if_statement "if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }" if (parenthesized_expression "(piVar4 != (int *)0x0)" ( (binary_expression "piVar4 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }" { (expression_statement "piVar7 = piVar4 + 0xf;" (assignment_expression "piVar7 = piVar4 + 0xf" identifier = (binary_expression "piVar4 + 0xf" identifier + number_literal)) ;) (expression_statement "*piVar4 = (int)piVar7;" (assignment_expression "*piVar4 = (int)piVar7" (pointer_expression "*piVar4" * identifier) = (cast_expression "(int)piVar7" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "piVar4[5] = (int)piVar7;" (assignment_expression "piVar4[5] = (int)piVar7" (subscript_expression "piVar4[5]" identifier [ number_literal ]) = (cast_expression "(int)piVar7" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "*(undefined1 *)(piVar4 + 1) = 1;" (assignment_expression "*(undefined1 *)(piVar4 + 1) = 1" (pointer_expression "*(undefined1 *)(piVar4 + 1)" * (cast_expression "(undefined1 *)(piVar4 + 1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar4 + 1)" ( (binary_expression "piVar4 + 1" identifier + number_literal) )))) = number_literal) ;) (expression_statement "piVar4[10] = (int)piVar7;" (assignment_expression "piVar4[10] = (int)piVar7" (subscript_expression "piVar4[10]" identifier [ number_literal ]) = (cast_expression "(int)piVar7" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "*(undefined1 *)(piVar4 + 6) = 2;" (assignment_expression "*(undefined1 *)(piVar4 + 6) = 2" (pointer_expression "*(undefined1 *)(piVar4 + 6)" * (cast_expression "(undefined1 *)(piVar4 + 6)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar4 + 6)" ( (binary_expression "piVar4 + 6" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined1 *)(piVar4 + 0xb) = 3;" (assignment_expression "*(undefined1 *)(piVar4 + 0xb) = 3" (pointer_expression "*(undefined1 *)(piVar4 + 0xb)" * (cast_expression "(undefined1 *)(piVar4 + 0xb)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar4 + 0xb)" ( (binary_expression "piVar4 + 0xb" identifier + number_literal) )))) = number_literal) ;) (expression_statement "uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);" (assignment_expression "uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2)" identifier = (call_expression "(*(code *)puVar1)(piVar7,param_2,iVar2)" (parenthesized_expression "(*(code *)puVar1)" ( (pointer_expression "*(code *)puVar1" * (cast_expression "(code *)puVar1" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(piVar7,param_2,iVar2)" ( identifier , identifier , identifier )))) ;) (expression_statement "iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);" (assignment_expression "iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4)" identifier = (call_expression "FUN_0003047c(param_1 + 0x184,uVar5,piVar4)" identifier (argument_list "(param_1 + 0x184,uVar5,piVar4)" ( (binary_expression "param_1 + 0x184" identifier + number_literal) , identifier , identifier )))) ;) (expression_statement "piVar7 = piVar4;" (assignment_expression "piVar7 = piVar4" identifier = identifier) ;) (if_statement "if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }" if (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) (compound_statement "{\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }" { (if_statement "if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }" if (parenthesized_expression "((*(uint *)(param_1 + 0x50) & 0xffff00) == 0)" ( (binary_expression "(*(uint *)(param_1 + 0x50) & 0xffff00) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0x50) & 0xffff00)" ( (binary_expression "*(uint *)(param_1 + 0x50) & 0xffff00" (pointer_expression "*(uint *)(param_1 + 0x50)" * (cast_expression "(uint *)(param_1 + 0x50)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x50)" ( (binary_expression "param_1 + 0x50" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n          FUN_0002d4c8(param_1);\n        }" { (expression_statement "FUN_0002d4c8(param_1);" (call_expression "FUN_0002d4c8(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) })) (expression_statement "FUN_0002a924(param_1,iVar2);" (call_expression "FUN_0002a924(param_1,iVar2)" identifier (argument_list "(param_1,iVar2)" ( identifier , identifier ))) ;) (expression_statement "piVar7 = piVar6;" (assignment_expression "piVar7 = piVar6" identifier = identifier) ;) })) })) })) (return_statement "return piVar7;" return identifier ;) })))
(translation_unit "CollSeq * findCollSeqEntry(sqlite3 *db,char *zName,int create)\n\n{\n  HashElem *pHVar1;\n  uint uVar2;\n  CollSeq *data;\n  char *pKey;\n  void *p;\n  CollSeq *pCVar3;\n  int iVar4;\n  code *pcVar5;\n  undefined1 *puVar6;\n  undefined4 in_stack_ffffffd4;\n  \n  puVar6 = &_gp;\n  pHVar1 = findElementWithHash(&db->aCollSeq,zName,(uint *)0x0);\n  pCVar3 = (CollSeq *)pHVar1->data;\n  if ((pCVar3 == (CollSeq *)0x0) && (create != 0)) {\n    if (zName == (char *)0x0) {\n      iVar4 = 1;\n    }\n    else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }\n    data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));\n    if (data != (CollSeq *)0x0) {\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }\n  }\n  return pCVar3;\n}\n\n" (function_definition "CollSeq * findCollSeqEntry(sqlite3 *db,char *zName,int create)\n\n{\n  HashElem *pHVar1;\n  uint uVar2;\n  CollSeq *data;\n  char *pKey;\n  void *p;\n  CollSeq *pCVar3;\n  int iVar4;\n  code *pcVar5;\n  undefined1 *puVar6;\n  undefined4 in_stack_ffffffd4;\n  \n  puVar6 = &_gp;\n  pHVar1 = findElementWithHash(&db->aCollSeq,zName,(uint *)0x0);\n  pCVar3 = (CollSeq *)pHVar1->data;\n  if ((pCVar3 == (CollSeq *)0x0) && (create != 0)) {\n    if (zName == (char *)0x0) {\n      iVar4 = 1;\n    }\n    else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }\n    data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));\n    if (data != (CollSeq *)0x0) {\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }\n  }\n  return pCVar3;\n}" type_identifier (pointer_declarator "* findCollSeqEntry(sqlite3 *db,char *zName,int create)" * (function_declarator "findCollSeqEntry(sqlite3 *db,char *zName,int create)" identifier (parameter_list "(sqlite3 *db,char *zName,int create)" ( (parameter_declaration "sqlite3 *db" type_identifier (pointer_declarator "*db" * identifier)) , (parameter_declaration "char *zName" primitive_type (pointer_declarator "*zName" * identifier)) , (parameter_declaration "int create" primitive_type identifier) )))) (compound_statement "{\n  HashElem *pHVar1;\n  uint uVar2;\n  CollSeq *data;\n  char *pKey;\n  void *p;\n  CollSeq *pCVar3;\n  int iVar4;\n  code *pcVar5;\n  undefined1 *puVar6;\n  undefined4 in_stack_ffffffd4;\n  \n  puVar6 = &_gp;\n  pHVar1 = findElementWithHash(&db->aCollSeq,zName,(uint *)0x0);\n  pCVar3 = (CollSeq *)pHVar1->data;\n  if ((pCVar3 == (CollSeq *)0x0) && (create != 0)) {\n    if (zName == (char *)0x0) {\n      iVar4 = 1;\n    }\n    else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }\n    data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));\n    if (data != (CollSeq *)0x0) {\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }\n  }\n  return pCVar3;\n}" { (declaration "HashElem *pHVar1;" type_identifier (pointer_declarator "*pHVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "CollSeq *data;" type_identifier (pointer_declarator "*data" * identifier) ;) (declaration "char *pKey;" primitive_type (pointer_declarator "*pKey" * identifier) ;) (declaration "void *p;" primitive_type (pointer_declarator "*p" * identifier) ;) (declaration "CollSeq *pCVar3;" type_identifier (pointer_declarator "*pCVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "code *pcVar5;" type_identifier (pointer_declarator "*pcVar5" * identifier) ;) (declaration "undefined1 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "undefined4 in_stack_ffffffd4;" type_identifier identifier ;) (expression_statement "puVar6 = &_gp;" (assignment_expression "puVar6 = &_gp" identifier = (pointer_expression "&_gp" & identifier)) ;) (expression_statement "pHVar1 = findElementWithHash(&db->aCollSeq,zName,(uint *)0x0);" (assignment_expression "pHVar1 = findElementWithHash(&db->aCollSeq,zName,(uint *)0x0)" identifier = (call_expression "findElementWithHash(&db->aCollSeq,zName,(uint *)0x0)" identifier (argument_list "(&db->aCollSeq,zName,(uint *)0x0)" ( (pointer_expression "&db->aCollSeq" & (field_expression "db->aCollSeq" identifier -> field_identifier)) , identifier , (cast_expression "(uint *)0x0" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) )))) ;) (expression_statement "pCVar3 = (CollSeq *)pHVar1->data;" (assignment_expression "pCVar3 = (CollSeq *)pHVar1->data" identifier = (cast_expression "(CollSeq *)pHVar1->data" ( (type_descriptor "CollSeq *" type_identifier (abstract_pointer_declarator "*" *)) ) (field_expression "pHVar1->data" identifier -> field_identifier))) ;) (if_statement "if ((pCVar3 == (CollSeq *)0x0) && (create != 0)) {\n    if (zName == (char *)0x0) {\n      iVar4 = 1;\n    }\n    else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }\n    data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));\n    if (data != (CollSeq *)0x0) {\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }\n  }" if (parenthesized_expression "((pCVar3 == (CollSeq *)0x0) && (create != 0))" ( (binary_expression "(pCVar3 == (CollSeq *)0x0) && (create != 0)" (parenthesized_expression "(pCVar3 == (CollSeq *)0x0)" ( (binary_expression "pCVar3 == (CollSeq *)0x0" identifier == (cast_expression "(CollSeq *)0x0" ( (type_descriptor "CollSeq *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(create != 0)" ( (binary_expression "create != 0" identifier != number_literal) ))) )) (compound_statement "{\n    if (zName == (char *)0x0) {\n      iVar4 = 1;\n    }\n    else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }\n    data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));\n    if (data != (CollSeq *)0x0) {\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }\n  }" { (if_statement "if (zName == (char *)0x0) {\n      iVar4 = 1;\n    }\n    else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }" if (parenthesized_expression "(zName == (char *)0x0)" ( (binary_expression "zName == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      iVar4 = 1;\n    }" { (expression_statement "iVar4 = 1;" (assignment_expression "iVar4 = 1" identifier = number_literal) ;) }) (else_clause "else {\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }" else (compound_statement "{\n      uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);\n      iVar4 = (uVar2 & 0x3fffffff) + 1;\n    }" { (expression_statement "uVar2 = (**(code **)(puVar6 + -0x7bec))(zName);" (assignment_expression "uVar2 = (**(code **)(puVar6 + -0x7bec))(zName)" identifier = (call_expression "(**(code **)(puVar6 + -0x7bec))(zName)" (parenthesized_expression "(**(code **)(puVar6 + -0x7bec))" ( (pointer_expression "**(code **)(puVar6 + -0x7bec)" * (pointer_expression "*(code **)(puVar6 + -0x7bec)" * (cast_expression "(code **)(puVar6 + -0x7bec)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar6 + -0x7bec)" ( (binary_expression "puVar6 + -0x7bec" identifier + number_literal) ))))) )) (argument_list "(zName)" ( identifier )))) ;) (expression_statement "iVar4 = (uVar2 & 0x3fffffff) + 1;" (assignment_expression "iVar4 = (uVar2 & 0x3fffffff) + 1" identifier = (binary_expression "(uVar2 & 0x3fffffff) + 1" (parenthesized_expression "(uVar2 & 0x3fffffff)" ( (binary_expression "uVar2 & 0x3fffffff" identifier & number_literal) )) + number_literal)) ;) }))) (expression_statement "data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4));" (assignment_expression "data = (CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4))" identifier = (cast_expression "(CollSeq *)sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4))" ( (type_descriptor "CollSeq *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "sqlite3DbMallocZero(db,CONCAT44(puVar6,in_stack_ffffffd4))" identifier (argument_list "(db,CONCAT44(puVar6,in_stack_ffffffd4))" ( identifier , (call_expression "CONCAT44(puVar6,in_stack_ffffffd4)" identifier (argument_list "(puVar6,in_stack_ffffffd4)" ( identifier , identifier ))) ))))) ;) (if_statement "if (data != (CollSeq *)0x0) {\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }" if (parenthesized_expression "(data != (CollSeq *)0x0)" ( (binary_expression "data != (CollSeq *)0x0" identifier != (cast_expression "(CollSeq *)0x0" ( (type_descriptor "CollSeq *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      pCVar3 = data + 3;\n      pcVar5 = *(code **)(puVar6 + -0x7b80);\n      data->zName = (char *)pCVar3;\n      data[1].zName = (char *)pCVar3;\n      data->enc = '\x01';\n      data[2].zName = (char *)pCVar3;\n      data[1].enc = '\x02';\n      data[2].enc = '\x03';\n      pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);\n      p = sqlite3HashInsert(&db->aCollSeq,pKey,data);\n      pCVar3 = data;\n      if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }\n    }" { (expression_statement "pCVar3 = data + 3;" (assignment_expression "pCVar3 = data + 3" identifier = (binary_expression "data + 3" identifier + number_literal)) ;) (expression_statement "pcVar5 = *(code **)(puVar6 + -0x7b80);" (assignment_expression "pcVar5 = *(code **)(puVar6 + -0x7b80)" identifier = (pointer_expression "*(code **)(puVar6 + -0x7b80)" * (cast_expression "(code **)(puVar6 + -0x7b80)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(puVar6 + -0x7b80)" ( (binary_expression "puVar6 + -0x7b80" identifier + number_literal) ))))) ;) (expression_statement "data->zName = (char *)pCVar3;" (assignment_expression "data->zName = (char *)pCVar3" (field_expression "data->zName" identifier -> field_identifier) = (cast_expression "(char *)pCVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "data[1].zName = (char *)pCVar3;" (assignment_expression "data[1].zName = (char *)pCVar3" (field_expression "data[1].zName" (subscript_expression "data[1]" identifier [ number_literal ]) . field_identifier) = (cast_expression "(char *)pCVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "data->enc = '\x01';" (assignment_expression "data->enc = '\x01'" (field_expression "data->enc" identifier -> field_identifier) = (char_literal "'\x01'" ' escape_sequence ')) ;) (expression_statement "data[2].zName = (char *)pCVar3;" (assignment_expression "data[2].zName = (char *)pCVar3" (field_expression "data[2].zName" (subscript_expression "data[2]" identifier [ number_literal ]) . field_identifier) = (cast_expression "(char *)pCVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "data[1].enc = '\x02';" (assignment_expression "data[1].enc = '\x02'" (field_expression "data[1].enc" (subscript_expression "data[1]" identifier [ number_literal ]) . field_identifier) = (char_literal "'\x02'" ' escape_sequence ')) ;) (expression_statement "data[2].enc = '\x03';" (assignment_expression "data[2].enc = '\x03'" (field_expression "data[2].enc" (subscript_expression "data[2]" identifier [ number_literal ]) . field_identifier) = (char_literal "'\x03'" ' escape_sequence ')) ;) (expression_statement "pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4);" (assignment_expression "pKey = (char *)(*pcVar5)(pCVar3,zName,iVar4)" identifier = (cast_expression "(char *)(*pcVar5)(pCVar3,zName,iVar4)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*pcVar5)(pCVar3,zName,iVar4)" (parenthesized_expression "(*pcVar5)" ( (pointer_expression "*pcVar5" * identifier) )) (argument_list "(pCVar3,zName,iVar4)" ( identifier , identifier , identifier ))))) ;) (expression_statement "p = sqlite3HashInsert(&db->aCollSeq,pKey,data);" (assignment_expression "p = sqlite3HashInsert(&db->aCollSeq,pKey,data)" identifier = (call_expression "sqlite3HashInsert(&db->aCollSeq,pKey,data)" identifier (argument_list "(&db->aCollSeq,pKey,data)" ( (pointer_expression "&db->aCollSeq" & (field_expression "db->aCollSeq" identifier -> field_identifier)) , identifier , identifier )))) ;) (expression_statement "pCVar3 = data;" (assignment_expression "pCVar3 = data" identifier = identifier) ;) (if_statement "if (p != (void *)0x0) {\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }" if (parenthesized_expression "(p != (void *)0x0)" ( (binary_expression "p != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        uVar2._0_1_ = db->temp_store;\n        uVar2._1_1_ = db->mallocFailed;\n        uVar2._2_1_ = db->bBenignMalloc;\n        uVar2._3_1_ = db->dfltLockMode;\n        if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }\n                    /* WARNING: Subroutine does not return */\n        sqlite3DbFreeNN(db,p);\n      }" { (expression_statement "uVar2._0_1_ = db->temp_store;" (assignment_expression "uVar2._0_1_ = db->temp_store" (field_expression "uVar2._0_1_" identifier . field_identifier) = (field_expression "db->temp_store" identifier -> field_identifier)) ;) (expression_statement "uVar2._1_1_ = db->mallocFailed;" (assignment_expression "uVar2._1_1_ = db->mallocFailed" (field_expression "uVar2._1_1_" identifier . field_identifier) = (field_expression "db->mallocFailed" identifier -> field_identifier)) ;) (expression_statement "uVar2._2_1_ = db->bBenignMalloc;" (assignment_expression "uVar2._2_1_ = db->bBenignMalloc" (field_expression "uVar2._2_1_" identifier . field_identifier) = (field_expression "db->bBenignMalloc" identifier -> field_identifier)) ;) (expression_statement "uVar2._3_1_ = db->dfltLockMode;" (assignment_expression "uVar2._3_1_ = db->dfltLockMode" (field_expression "uVar2._3_1_" identifier . field_identifier) = (field_expression "db->dfltLockMode" identifier -> field_identifier)) ;) (if_statement "if ((uVar2 & 0xffff00) == 0) {\n          sqlite3OomFault(db);\n        }" if (parenthesized_expression "((uVar2 & 0xffff00) == 0)" ( (binary_expression "(uVar2 & 0xffff00) == 0" (parenthesized_expression "(uVar2 & 0xffff00)" ( (binary_expression "uVar2 & 0xffff00" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n          sqlite3OomFault(db);\n        }" { (expression_statement "sqlite3OomFault(db);" (call_expression "sqlite3OomFault(db)" identifier (argument_list "(db)" ( identifier ))) ;) })) comment (expression_statement "sqlite3DbFreeNN(db,p);" (call_expression "sqlite3DbFreeNN(db,p)" identifier (argument_list "(db,p)" ( identifier , identifier ))) ;) })) })) })) (return_statement "return pCVar3;" return identifier ;) })))
(translation_unit "int * FUN_00030820(int param_1,int param_2,int param_3)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}\n\n" (function_definition "int * FUN_00030820(int param_1,int param_2,int param_3)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}" primitive_type (pointer_declarator "* FUN_00030820(int param_1,int param_2,int param_3)" * (function_declarator "FUN_00030820(int param_1,int param_2,int param_3)" identifier (parameter_list "(int param_1,int param_2,int param_3)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "int param_3" primitive_type identifier) )))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "undefined4 uVar5;" type_identifier identifier ;) (declaration "int *piVar6;" primitive_type (pointer_declarator "*piVar6" * identifier) ;) (declaration "int *piVar7;" primitive_type (pointer_declarator "*piVar7" * identifier) ;) (expression_statement "iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);" (assignment_expression "iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0)" identifier = (call_expression "FUN_0001d764(param_1 + 0x184,param_2,0)" identifier (argument_list "(param_1 + 0x184,param_2,0)" ( (binary_expression "param_1 + 0x184" identifier + number_literal) , identifier , number_literal )))) ;) (expression_statement "piVar6 = *(int **)(iVar2 + 8);" (assignment_expression "piVar6 = *(int **)(iVar2 + 8)" identifier = (pointer_expression "*(int **)(iVar2 + 8)" * (cast_expression "(int **)(iVar2 + 8)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(iVar2 + 8)" ( (binary_expression "iVar2 + 8" identifier + number_literal) ))))) ;) (expression_statement "piVar7 = piVar6;" (assignment_expression "piVar7 = piVar6" identifier = identifier) ;) (if_statement "if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }" if (parenthesized_expression "((piVar6 == (int *)0x0) && (param_3 != 0))" ( (binary_expression "(piVar6 == (int *)0x0) && (param_3 != 0)" (parenthesized_expression "(piVar6 == (int *)0x0)" ( (binary_expression "piVar6 == (int *)0x0" identifier == (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(param_3 != 0)" ( (binary_expression "param_3 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }" { (if_statement "if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar2 = 1;\n    }" { (expression_statement "iVar2 = 1;" (assignment_expression "iVar2 = 1" identifier = number_literal) ;) }) (else_clause "else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" else (compound_statement "{\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" { (expression_statement "uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);" (assignment_expression "uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2)" identifier = (call_expression "(*(code *)PTR_strlen_0015b9c4)(param_2)" (parenthesized_expression "(*(code *)PTR_strlen_0015b9c4)" ( (pointer_expression "*(code *)PTR_strlen_0015b9c4" * (cast_expression "(code *)PTR_strlen_0015b9c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "iVar2 = (uVar3 & 0x3fffffff) + 1;" (assignment_expression "iVar2 = (uVar3 & 0x3fffffff) + 1" identifier = (binary_expression "(uVar3 & 0x3fffffff) + 1" (parenthesized_expression "(uVar3 & 0x3fffffff)" ( (binary_expression "uVar3 & 0x3fffffff" identifier & number_literal) )) + number_literal)) ;) }))) (expression_statement "piVar4 = (int *)FUN_0002d5c0(param_1);" (assignment_expression "piVar4 = (int *)FUN_0002d5c0(param_1)" identifier = (cast_expression "(int *)FUN_0002d5c0(param_1)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0002d5c0(param_1)" identifier (argument_list "(param_1)" ( identifier ))))) ;) (expression_statement "puVar1 = PTR_memcpy_0015ba30;" (assignment_expression "puVar1 = PTR_memcpy_0015ba30" identifier = identifier) ;) (if_statement "if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }" if (parenthesized_expression "(piVar4 != (int *)0x0)" ( (binary_expression "piVar4 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }" { (expression_statement "piVar7 = piVar4 + 0xf;" (assignment_expression "piVar7 = piVar4 + 0xf" identifier = (binary_expression "piVar4 + 0xf" identifier + number_literal)) ;) (expression_statement "*piVar4 = (int)piVar7;" (assignment_expression "*piVar4 = (int)piVar7" (pointer_expression "*piVar4" * identifier) = (cast_expression "(int)piVar7" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "piVar4[5] = (int)piVar7;" (assignment_expression "piVar4[5] = (int)piVar7" (subscript_expression "piVar4[5]" identifier [ number_literal ]) = (cast_expression "(int)piVar7" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "*(undefined1 *)(piVar4 + 1) = 1;" (assignment_expression "*(undefined1 *)(piVar4 + 1) = 1" (pointer_expression "*(undefined1 *)(piVar4 + 1)" * (cast_expression "(undefined1 *)(piVar4 + 1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar4 + 1)" ( (binary_expression "piVar4 + 1" identifier + number_literal) )))) = number_literal) ;) (expression_statement "piVar4[10] = (int)piVar7;" (assignment_expression "piVar4[10] = (int)piVar7" (subscript_expression "piVar4[10]" identifier [ number_literal ]) = (cast_expression "(int)piVar7" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "*(undefined1 *)(piVar4 + 6) = 2;" (assignment_expression "*(undefined1 *)(piVar4 + 6) = 2" (pointer_expression "*(undefined1 *)(piVar4 + 6)" * (cast_expression "(undefined1 *)(piVar4 + 6)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar4 + 6)" ( (binary_expression "piVar4 + 6" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined1 *)(piVar4 + 0xb) = 3;" (assignment_expression "*(undefined1 *)(piVar4 + 0xb) = 3" (pointer_expression "*(undefined1 *)(piVar4 + 0xb)" * (cast_expression "(undefined1 *)(piVar4 + 0xb)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar4 + 0xb)" ( (binary_expression "piVar4 + 0xb" identifier + number_literal) )))) = number_literal) ;) (expression_statement "uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);" (assignment_expression "uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2)" identifier = (call_expression "(*(code *)puVar1)(piVar7,param_2,iVar2)" (parenthesized_expression "(*(code *)puVar1)" ( (pointer_expression "*(code *)puVar1" * (cast_expression "(code *)puVar1" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(piVar7,param_2,iVar2)" ( identifier , identifier , identifier )))) ;) (expression_statement "iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);" (assignment_expression "iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4)" identifier = (call_expression "FUN_0003047c(param_1 + 0x184,uVar5,piVar4)" identifier (argument_list "(param_1 + 0x184,uVar5,piVar4)" ( (binary_expression "param_1 + 0x184" identifier + number_literal) , identifier , identifier )))) ;) (expression_statement "piVar7 = piVar4;" (assignment_expression "piVar7 = piVar4" identifier = identifier) ;) (if_statement "if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }" if (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) (compound_statement "{\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }" { (if_statement "if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }" if (parenthesized_expression "((*(uint *)(param_1 + 0x50) & 0xffff00) == 0)" ( (binary_expression "(*(uint *)(param_1 + 0x50) & 0xffff00) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0x50) & 0xffff00)" ( (binary_expression "*(uint *)(param_1 + 0x50) & 0xffff00" (pointer_expression "*(uint *)(param_1 + 0x50)" * (cast_expression "(uint *)(param_1 + 0x50)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x50)" ( (binary_expression "param_1 + 0x50" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n          FUN_0002d4c8(param_1);\n        }" { (expression_statement "FUN_0002d4c8(param_1);" (call_expression "FUN_0002d4c8(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) })) (expression_statement "FUN_0002a924(param_1,iVar2);" (call_expression "FUN_0002a924(param_1,iVar2)" identifier (argument_list "(param_1,iVar2)" ( identifier , identifier ))) ;) (expression_statement "piVar7 = piVar6;" (assignment_expression "piVar7 = piVar6" identifier = identifier) ;) })) })) })) (return_statement "return piVar7;" return identifier ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) )))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (binary_expression IDENT + LIT) , IDENT , 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) ))))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) (compound_statement { (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 = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) + LIT)) ;) }))) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT ))))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_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) )))) = LIT) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , IDENT , IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (binary_expression IDENT + LIT) , IDENT , IDENT )))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != 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 ( IDENT ))) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) })) })) (return_statement return IDENT ;) })))
(function_definition "int * FUN_00030820(int param_1,int param_2,int param_3)\n\n{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}" (primitive_type "int") (pointer_declarator "* FUN_00030820(int param_1,int param_2,int param_3)" (* "*") (function_declarator "FUN_00030820(int param_1,int param_2,int param_3)" (identifier "FUN_00030820") (parameter_list "(int param_1,int param_2,int param_3)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) (, ",") (parameter_declaration "int param_3" (primitive_type "int") (identifier "param_3")) () ")")))) (compound_statement "{\n  undefined *puVar1;\n  int iVar2;\n  uint uVar3;\n  int *piVar4;\n  undefined4 uVar5;\n  int *piVar6;\n  int *piVar7;\n  \n  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);\n  piVar6 = *(int **)(iVar2 + 8);\n  piVar7 = piVar6;\n  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }\n  return piVar7;\n}" ({ "{") (declaration "undefined *puVar1;" (type_identifier "undefined") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "uint uVar3;" (type_identifier "uint") (identifier "uVar3") (; ";")) (declaration "int *piVar4;" (primitive_type "int") (pointer_declarator "*piVar4" (* "*") (identifier "piVar4")) (; ";")) (declaration "undefined4 uVar5;" (type_identifier "undefined4") (identifier "uVar5") (; ";")) (declaration "int *piVar6;" (primitive_type "int") (pointer_declarator "*piVar6" (* "*") (identifier "piVar6")) (; ";")) (declaration "int *piVar7;" (primitive_type "int") (pointer_declarator "*piVar7" (* "*") (identifier "piVar7")) (; ";")) (expression_statement "iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);" (assignment_expression "iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0)" (identifier "iVar2") (= "=") (call_expression "FUN_0001d764(param_1 + 0x184,param_2,0)" (identifier "FUN_0001d764") (argument_list "(param_1 + 0x184,param_2,0)" (( "(") (binary_expression "param_1 + 0x184" (identifier "param_1") (+ "+") (number_literal "0x184")) (, ",") (identifier "param_2") (, ",") (number_literal "0") () ")")))) (; ";")) (expression_statement "piVar6 = *(int **)(iVar2 + 8);" (assignment_expression "piVar6 = *(int **)(iVar2 + 8)" (identifier "piVar6") (= "=") (pointer_expression "*(int **)(iVar2 + 8)" (* "*") (cast_expression "(int **)(iVar2 + 8)" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(iVar2 + 8)" (( "(") (binary_expression "iVar2 + 8" (identifier "iVar2") (+ "+") (number_literal "8")) () ")"))))) (; ";")) (expression_statement "piVar7 = piVar6;" (assignment_expression "piVar7 = piVar6" (identifier "piVar7") (= "=") (identifier "piVar6")) (; ";")) (if_statement "if ((piVar6 == (int *)0x0) && (param_3 != 0)) {\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }" (if "if") (parenthesized_expression "((piVar6 == (int *)0x0) && (param_3 != 0))" (( "(") (binary_expression "(piVar6 == (int *)0x0) && (param_3 != 0)" (parenthesized_expression "(piVar6 == (int *)0x0)" (( "(") (binary_expression "piVar6 == (int *)0x0" (identifier "piVar6") (== "==") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(param_3 != 0)" (( "(") (binary_expression "param_3 != 0" (identifier "param_3") (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n    if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }\n    piVar4 = (int *)FUN_0002d5c0(param_1);\n    puVar1 = PTR_memcpy_0015ba30;\n    if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }\n  }" ({ "{") (if_statement "if (param_2 == 0) {\n      iVar2 = 1;\n    }\n    else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" (if "if") (parenthesized_expression "(param_2 == 0)" (( "(") (binary_expression "param_2 == 0" (identifier "param_2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      iVar2 = 1;\n    }" ({ "{") (expression_statement "iVar2 = 1;" (assignment_expression "iVar2 = 1" (identifier "iVar2") (= "=") (number_literal "1")) (; ";")) (} "}")) (else_clause "else {\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" (else "else") (compound_statement "{\n      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);\n      iVar2 = (uVar3 & 0x3fffffff) + 1;\n    }" ({ "{") (expression_statement "uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);" (assignment_expression "uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2)" (identifier "uVar3") (= "=") (call_expression "(*(code *)PTR_strlen_0015b9c4)(param_2)" (parenthesized_expression "(*(code *)PTR_strlen_0015b9c4)" (( "(") (pointer_expression "*(code *)PTR_strlen_0015b9c4" (* "*") (cast_expression "(code *)PTR_strlen_0015b9c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_strlen_0015b9c4"))) () ")")) (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (expression_statement "iVar2 = (uVar3 & 0x3fffffff) + 1;" (assignment_expression "iVar2 = (uVar3 & 0x3fffffff) + 1" (identifier "iVar2") (= "=") (binary_expression "(uVar3 & 0x3fffffff) + 1" (parenthesized_expression "(uVar3 & 0x3fffffff)" (( "(") (binary_expression "uVar3 & 0x3fffffff" (identifier "uVar3") (& "&") (number_literal "0x3fffffff")) () ")")) (+ "+") (number_literal "1"))) (; ";")) (} "}")))) (expression_statement "piVar4 = (int *)FUN_0002d5c0(param_1);" (assignment_expression "piVar4 = (int *)FUN_0002d5c0(param_1)" (identifier "piVar4") (= "=") (cast_expression "(int *)FUN_0002d5c0(param_1)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0002d5c0(param_1)" (identifier "FUN_0002d5c0") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))))) (; ";")) (expression_statement "puVar1 = PTR_memcpy_0015ba30;" (assignment_expression "puVar1 = PTR_memcpy_0015ba30" (identifier "puVar1") (= "=") (identifier "PTR_memcpy_0015ba30")) (; ";")) (if_statement "if (piVar4 != (int *)0x0) {\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }" (if "if") (parenthesized_expression "(piVar4 != (int *)0x0)" (( "(") (binary_expression "piVar4 != (int *)0x0" (identifier "piVar4") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n      piVar7 = piVar4 + 0xf;\n      *piVar4 = (int)piVar7;\n      piVar4[5] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 1) = 1;\n      piVar4[10] = (int)piVar7;\n      *(undefined1 *)(piVar4 + 6) = 2;\n      *(undefined1 *)(piVar4 + 0xb) = 3;\n      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);\n      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);\n      piVar7 = piVar4;\n      if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }\n    }" ({ "{") (expression_statement "piVar7 = piVar4 + 0xf;" (assignment_expression "piVar7 = piVar4 + 0xf" (identifier "piVar7") (= "=") (binary_expression "piVar4 + 0xf" (identifier "piVar4") (+ "+") (number_literal "0xf"))) (; ";")) (expression_statement "*piVar4 = (int)piVar7;" (assignment_expression "*piVar4 = (int)piVar7" (pointer_expression "*piVar4" (* "*") (identifier "piVar4")) (= "=") (cast_expression "(int)piVar7" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "piVar7"))) (; ";")) (expression_statement "piVar4[5] = (int)piVar7;" (assignment_expression "piVar4[5] = (int)piVar7" (subscript_expression "piVar4[5]" (identifier "piVar4") ([ "[") (number_literal "5") (] "]")) (= "=") (cast_expression "(int)piVar7" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "piVar7"))) (; ";")) (expression_statement "*(undefined1 *)(piVar4 + 1) = 1;" (assignment_expression "*(undefined1 *)(piVar4 + 1) = 1" (pointer_expression "*(undefined1 *)(piVar4 + 1)" (* "*") (cast_expression "(undefined1 *)(piVar4 + 1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(piVar4 + 1)" (( "(") (binary_expression "piVar4 + 1" (identifier "piVar4") (+ "+") (number_literal "1")) () ")")))) (= "=") (number_literal "1")) (; ";")) (expression_statement "piVar4[10] = (int)piVar7;" (assignment_expression "piVar4[10] = (int)piVar7" (subscript_expression "piVar4[10]" (identifier "piVar4") ([ "[") (number_literal "10") (] "]")) (= "=") (cast_expression "(int)piVar7" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "piVar7"))) (; ";")) (expression_statement "*(undefined1 *)(piVar4 + 6) = 2;" (assignment_expression "*(undefined1 *)(piVar4 + 6) = 2" (pointer_expression "*(undefined1 *)(piVar4 + 6)" (* "*") (cast_expression "(undefined1 *)(piVar4 + 6)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(piVar4 + 6)" (( "(") (binary_expression "piVar4 + 6" (identifier "piVar4") (+ "+") (number_literal "6")) () ")")))) (= "=") (number_literal "2")) (; ";")) (expression_statement "*(undefined1 *)(piVar4 + 0xb) = 3;" (assignment_expression "*(undefined1 *)(piVar4 + 0xb) = 3" (pointer_expression "*(undefined1 *)(piVar4 + 0xb)" (* "*") (cast_expression "(undefined1 *)(piVar4 + 0xb)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(piVar4 + 0xb)" (( "(") (binary_expression "piVar4 + 0xb" (identifier "piVar4") (+ "+") (number_literal "0xb")) () ")")))) (= "=") (number_literal "3")) (; ";")) (expression_statement "uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);" (assignment_expression "uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2)" (identifier "uVar5") (= "=") (call_expression "(*(code *)puVar1)(piVar7,param_2,iVar2)" (parenthesized_expression "(*(code *)puVar1)" (( "(") (pointer_expression "*(code *)puVar1" (* "*") (cast_expression "(code *)puVar1" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "puVar1"))) () ")")) (argument_list "(piVar7,param_2,iVar2)" (( "(") (identifier "piVar7") (, ",") (identifier "param_2") (, ",") (identifier "iVar2") () ")")))) (; ";")) (expression_statement "iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);" (assignment_expression "iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4)" (identifier "iVar2") (= "=") (call_expression "FUN_0003047c(param_1 + 0x184,uVar5,piVar4)" (identifier "FUN_0003047c") (argument_list "(param_1 + 0x184,uVar5,piVar4)" (( "(") (binary_expression "param_1 + 0x184" (identifier "param_1") (+ "+") (number_literal "0x184")) (, ",") (identifier "uVar5") (, ",") (identifier "piVar4") () ")")))) (; ";")) (expression_statement "piVar7 = piVar4;" (assignment_expression "piVar7 = piVar4" (identifier "piVar7") (= "=") (identifier "piVar4")) (; ";")) (if_statement "if (iVar2 != 0) {\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }" (if "if") (parenthesized_expression "(iVar2 != 0)" (( "(") (binary_expression "iVar2 != 0" (identifier "iVar2") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }\n        FUN_0002a924(param_1,iVar2);\n        piVar7 = piVar6;\n      }" ({ "{") (if_statement "if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {\n          FUN_0002d4c8(param_1);\n        }" (if "if") (parenthesized_expression "((*(uint *)(param_1 + 0x50) & 0xffff00) == 0)" (( "(") (binary_expression "(*(uint *)(param_1 + 0x50) & 0xffff00) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0x50) & 0xffff00)" (( "(") (binary_expression "*(uint *)(param_1 + 0x50) & 0xffff00" (pointer_expression "*(uint *)(param_1 + 0x50)" (* "*") (cast_expression "(uint *)(param_1 + 0x50)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x50)" (( "(") (binary_expression "param_1 + 0x50" (identifier "param_1") (+ "+") (number_literal "0x50")) () ")")))) (& "&") (number_literal "0xffff00")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          FUN_0002d4c8(param_1);\n        }" ({ "{") (expression_statement "FUN_0002d4c8(param_1);" (call_expression "FUN_0002d4c8(param_1)" (identifier "FUN_0002d4c8") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (} "}"))) (expression_statement "FUN_0002a924(param_1,iVar2);" (call_expression "FUN_0002a924(param_1,iVar2)" (identifier "FUN_0002a924") (argument_list "(param_1,iVar2)" (( "(") (identifier "param_1") (, ",") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "piVar7 = piVar6;" (assignment_expression "piVar7 = piVar6" (identifier "piVar7") (= "=") (identifier "piVar6")) (; ";")) (} "}"))) (} "}"))) (} "}"))) (return_statement "return piVar7;" (return "return") (identifier "piVar7") (; ";")) (} "}")))

type_1 * function_1(type_2 *db,char *var_4,int var_3)

{
  type_3 *pHVar1;
  type_4 var_6;
  type_1 *var_9;
  char *pKey;
  void *var_11;
  type_1 *var_2;
  int iVar4;
  type_5 *pcVar5;
  type_6 *var_5;
  type_7 in_stack_ffffffd4;
  
  var_5 = &_gp;
  pHVar1 = var_1(&db->aCollSeq,var_4,(type_4 *)0x0);
  var_2 = (type_1 *)pHVar1->var_9;
  if ((var_2 == (type_1 *)0x0) && (var_3 != 0)) {
    if (var_4 == (char *)0x0) {
      iVar4 = 1;
    }
    else {
      var_6 = (**(type_5 **)(var_5 + -0x7bec))(var_4);
      iVar4 = (var_6 & 0x3fffffff) + 1;
    }
    var_9 = (type_1 *)var_7(db,var_8(var_5,in_stack_ffffffd4));
    if (var_9 != (type_1 *)0x0) {
      var_2 = var_9 + 3;
      pcVar5 = *(type_5 **)(var_5 + -0x7b80);
      var_9->var_4 = (char *)var_2;
      var_9[1].var_4 = (char *)var_2;
      var_9->enc = '\x01';
      var_9[2].var_4 = (char *)var_2;
      var_9[1].enc = '\x02';
      var_9[2].enc = '\x03';
      pKey = (char *)(*pcVar5)(var_2,var_4,iVar4);
      var_11 = var_10(&db->aCollSeq,pKey,var_9);
      var_2 = var_9;
      if (var_11 != (void *)0x0) {
        var_6._0_1_ = db->temp_store;
        var_6._1_1_ = db->mallocFailed;
        var_6._2_1_ = db->bBenignMalloc;
        var_6._3_1_ = db->dfltLockMode;
        if ((var_6 & 0xffff00) == 0) {
          var_12(db);
        }
                    /* WARNING: Subroutine does not return */
        var_13(db,var_11);
      }
    }
  }
  return var_2;
}


(translation_unit (function_definition type: (primitive_type) declarator: (pointer_declarator declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier))))) body: (compound_statement (declaration type: (type_identifier) declarator: (pointer_declarator 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: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (number_literal)) (identifier) (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))))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (compound_statement (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: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (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 (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (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: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (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: (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))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (identifier) (identifier) (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (number_literal)) (identifier) (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (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 (identifier)))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))))))))) (return_statement (identifier)))))

int * MASKED(int param_1,int param_2,int param_3)

{
  undefined *puVar1;
  int iVar2;
  uint uVar3;
  int *piVar4;
  undefined4 uVar5;
  int *piVar6;
  int *piVar7;
  
  iVar2 = FUN_0001d764(param_1 + 0x184,param_2,0);
  piVar6 = *(int **)(iVar2 + 8);
  piVar7 = piVar6;
  if ((piVar6 == (int *)0x0) && (param_3 != 0)) {
    if (param_2 == 0) {
      iVar2 = 1;
    }
    else {
      uVar3 = (*(code *)PTR_strlen_0015b9c4)(param_2);
      iVar2 = (uVar3 & 0x3fffffff) + 1;
    }
    piVar4 = (int *)FUN_0002d5c0(param_1);
    puVar1 = PTR_memcpy_0015ba30;
    if (piVar4 != (int *)0x0) {
      piVar7 = piVar4 + 0xf;
      *piVar4 = (int)piVar7;
      piVar4[5] = (int)piVar7;
      *(undefined1 *)(piVar4 + 1) = 1;
      piVar4[10] = (int)piVar7;
      *(undefined1 *)(piVar4 + 6) = 2;
      *(undefined1 *)(piVar4 + 0xb) = 3;
      uVar5 = (*(code *)puVar1)(piVar7,param_2,iVar2);
      iVar2 = FUN_0003047c(param_1 + 0x184,uVar5,piVar4);
      piVar7 = piVar4;
      if (iVar2 != 0) {
        if ((*(uint *)(param_1 + 0x50) & 0xffff00) == 0) {
          FUN_0002d4c8(param_1);
        }
        FUN_0002a924(param_1,iVar2);
        piVar7 = piVar6;
      }
    }
  }
  return piVar7;
}

