
IdList * sqlite3IdListDup(sqlite3 *db,IdList *p)

{
  IdList *p_00;
  IdList_item *pIVar1;
  char *pcVar2;
  IdList_item *pIVar3;
  int iVar4;
  undefined1 *puVar5;
  undefined4 in_stack_ffffffdc;
  
  puVar5 = &_gp;
  if ((p != (IdList *)0x0) && (db->mallocFailed == '\0')) {
    p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));
    if (p_00 != (IdList *)0x0) {
      p_00->nId = p->nId;
      if (db->mallocFailed == '\0') {
        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));
        p_00->a = pIVar1;
        if (pIVar1 != (IdList_item *)0x0) {
          if (0 < p->nId) {
            iVar4 = 0;
            while( true ) {
              pIVar1 = pIVar1 + iVar4;
              pIVar3 = p->a + iVar4;
              iVar4 = iVar4 + 1;
              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);
              pIVar1->zName = pcVar2;
              pIVar1->idx = pIVar3->idx;
              if (p->nId <= iVar4) break;
              pIVar1 = p_00->a;
            }
          }
          return p_00;
        }
      }
      else {
        p_00->a = (IdList_item *)0x0;
      }
                    /* WARNING: Subroutine does not return */
      sqlite3DbFreeNN(db,p_00);
    }
  }
  return (IdList *)0x0;
}



int * FUN_00051a3c(int param_1,int *param_2)

{
  int *piVar1;
  int iVar2;
  undefined4 uVar3;
  undefined4 *puVar4;
  undefined4 *puVar5;
  int iVar6;
  
  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&
     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {
    piVar1[1] = param_2[1];
    if (*(char *)(param_1 + 0x51) == '\0') {
      iVar2 = FUN_00050854(param_1);
      *piVar1 = iVar2;
      if (iVar2 != 0) {
        if (param_2[1] < 1) {
          return piVar1;
        }
        iVar6 = 0;
        while( true ) {
          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);
          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);
          iVar6 = iVar6 + 1;
          uVar3 = FUN_00050fc4(param_1,*puVar5);
          *puVar4 = uVar3;
          puVar4[1] = puVar5[1];
          if (param_2[1] <= iVar6) break;
          iVar2 = *piVar1;
        }
        return piVar1;
      }
    }
    else {
      *piVar1 = 0;
    }
    FUN_0004dc98(param_1,piVar1);
    return (int *)0x0;
  }
  return (int *)0x0;
}


lui gp,0x14
addiu gp,gp,0x6ee4
addu gp,gp,t9
addiu sp,sp,-0x38
sw gp,0x10(sp)
sw ra,0x34(sp)
sw s6,0x30(sp)
sw s5,0x2c(sp)
sw s4,0x28(sp)
sw s3,0x24(sp)
sw s2,0x20(sp)
sw s1,0x1c(sp)
beq a1,zero,0x00051b60
_sw s0,0x18(sp)
lbu v0,0x51(a0)
bne v0,zero,0x00051b60
_or s3,a0,zero
lw s0,-0x7d78(gp)
li a3,0x8
or a2,zero,zero
addiu s0,s0,0x854
or t9,s0,zero
bal 0x00050854
_or s6,a1,zero
lw gp,0x10(sp)
beq v0,zero,0x00051b60
_or s4,v0,zero
lw a3,0x4(s6)
sw a3,0x4(v0)
lbu v0,0x51(s3)
bne v0,zero,0x00051b90
_or a2,zero,zero
sll a3,a3,0x3
or t9,s0,zero
bal 0x00050854
_or a0,s3,zero
lw gp,0x10(sp)
beq v0,zero,0x00051b94
_sw v0,0x0(s4)
lw v1,0x4(s6)
blez v1,0x00051b34
_lw s5,-0x7d78(gp)
or s2,zero,zero
b 0x00051af4
_addiu s5,s5,0xfc4
lw v0,0x0(s4)
lw s1,0x0(s6)
sll v1,s2,0x3
or a0,s3,zero
addu s0,v0,v1
addu s1,s1,v1
or t9,s5,zero
addiu s2,s2,0x1
bal 0x00050fc4
_lw a1,0x0(s1)
sw v0,0x0(s0)
lw v0,0x4(s1)
sw v0,0x4(s0)
lw v0,0x4(s6)
slt v0,s2,v0
bne v0,zero,0x00051af0
_nop
lw ra,0x34(sp)
or v0,s4,zero
lw s6,0x30(sp)
lw s5,0x2c(sp)
lw s4,0x28(sp)
lw s3,0x24(sp)
lw s2,0x20(sp)
lw s1,0x1c(sp)
lw s0,0x18(sp)
jr ra
_addiu sp,sp,0x38
lw ra,0x34(sp)
or s4,zero,zero
lw s6,0x30(sp)
or v0,s4,zero
lw s5,0x2c(sp)
lw s4,0x28(sp)
lw s3,0x24(sp)
lw s2,0x20(sp)
lw s1,0x1c(sp)
lw s0,0x18(sp)
jr ra
_addiu sp,sp,0x38
sw zero,0x0(s4)
lw t9,-0x7d78(gp)
or a1,s4,zero
or a0,s3,zero
addiu t9,t9,-0x2368
bal 0x0004dc98
_or s4,zero,zero
b 0x00051b38
_lw ra,0x34(sp)
(translation_unit "int * FUN_00051a3c(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}\n\n" (function_definition "int * FUN_00051a3c(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}" primitive_type (pointer_declarator "* FUN_00051a3c(int param_1,int *param_2)" * (function_declarator "FUN_00051a3c(int param_1,int *param_2)" identifier (parameter_list "(int param_1,int *param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) )))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "undefined4 uVar3;" type_identifier identifier ;) (declaration "undefined4 *puVar4;" type_identifier (pointer_declarator "*puVar4" * identifier) ;) (declaration "undefined4 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (if_statement "if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }" if (parenthesized_expression "(((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0))" ( (binary_expression "((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)" (parenthesized_expression "((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0'))" ( (binary_expression "(param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')" (parenthesized_expression "(param_2 != (int *)0x0)" ( (binary_expression "param_2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*(char *)(param_1 + 0x51) == '\0')" ( (binary_expression "*(char *)(param_1 + 0x51) == '\0'" (pointer_expression "*(char *)(param_1 + 0x51)" * (cast_expression "(char *)(param_1 + 0x51)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x51)" ( (binary_expression "param_1 + 0x51" identifier + number_literal) )))) == (char_literal "'\0'" ' escape_sequence ')) ))) )) && (parenthesized_expression "(piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)" ( (comma_expression "piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0" (assignment_expression "piVar1 = (int *)FUN_00050854(param_1,param_2,0,8)" identifier = (cast_expression "(int *)FUN_00050854(param_1,param_2,0,8)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_00050854(param_1,param_2,0,8)" identifier (argument_list "(param_1,param_2,0,8)" ( identifier , identifier , number_literal , number_literal ))))) , (binary_expression "piVar1 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal))) ))) )) (compound_statement "{\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }" { (expression_statement "piVar1[1] = param_2[1];" (assignment_expression "piVar1[1] = param_2[1]" (subscript_expression "piVar1[1]" identifier [ number_literal ]) = (subscript_expression "param_2[1]" identifier [ number_literal ])) ;) (if_statement "if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }" if (parenthesized_expression "(*(char *)(param_1 + 0x51) == '\0')" ( (binary_expression "*(char *)(param_1 + 0x51) == '\0'" (pointer_expression "*(char *)(param_1 + 0x51)" * (cast_expression "(char *)(param_1 + 0x51)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x51)" ( (binary_expression "param_1 + 0x51" identifier + number_literal) )))) == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }" { (expression_statement "iVar2 = FUN_00050854(param_1);" (assignment_expression "iVar2 = FUN_00050854(param_1)" identifier = (call_expression "FUN_00050854(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (expression_statement "*piVar1 = iVar2;" (assignment_expression "*piVar1 = iVar2" (pointer_expression "*piVar1" * identifier) = identifier) ;) (if_statement "if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }" if (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) (compound_statement "{\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }" { (if_statement "if (param_2[1] < 1) {\n          return piVar1;\n        }" if (parenthesized_expression "(param_2[1] < 1)" ( (binary_expression "param_2[1] < 1" (subscript_expression "param_2[1]" identifier [ number_literal ]) < number_literal) )) (compound_statement "{\n          return piVar1;\n        }" { (return_statement "return piVar1;" return identifier ;) })) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }" { (expression_statement "puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);" (assignment_expression "puVar4 = (undefined4 *)(iVar2 + iVar6 * 8)" identifier = (cast_expression "(undefined4 *)(iVar2 + iVar6 * 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar2 + iVar6 * 8)" ( (binary_expression "iVar2 + iVar6 * 8" identifier + (binary_expression "iVar6 * 8" identifier * number_literal)) )))) ;) (expression_statement "puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);" (assignment_expression "puVar5 = (undefined4 *)(*param_2 + iVar6 * 8)" identifier = (cast_expression "(undefined4 *)(*param_2 + iVar6 * 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_2 + iVar6 * 8)" ( (binary_expression "*param_2 + iVar6 * 8" (pointer_expression "*param_2" * identifier) + (binary_expression "iVar6 * 8" identifier * number_literal)) )))) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "uVar3 = FUN_00050fc4(param_1,*puVar5);" (assignment_expression "uVar3 = FUN_00050fc4(param_1,*puVar5)" identifier = (call_expression "FUN_00050fc4(param_1,*puVar5)" identifier (argument_list "(param_1,*puVar5)" ( identifier , (pointer_expression "*puVar5" * identifier) )))) ;) (expression_statement "*puVar4 = uVar3;" (assignment_expression "*puVar4 = uVar3" (pointer_expression "*puVar4" * identifier) = identifier) ;) (expression_statement "puVar4[1] = puVar5[1];" (assignment_expression "puVar4[1] = puVar5[1]" (subscript_expression "puVar4[1]" identifier [ number_literal ]) = (subscript_expression "puVar5[1]" identifier [ number_literal ])) ;) (if_statement "if (param_2[1] <= iVar6) break;" if (parenthesized_expression "(param_2[1] <= iVar6)" ( (binary_expression "param_2[1] <= iVar6" (subscript_expression "param_2[1]" identifier [ number_literal ]) <= identifier) )) (break_statement "break;" break ;)) (expression_statement "iVar2 = *piVar1;" (assignment_expression "iVar2 = *piVar1" identifier = (pointer_expression "*piVar1" * identifier)) ;) })) (return_statement "return piVar1;" return identifier ;) })) }) (else_clause "else {\n      *piVar1 = 0;\n    }" else (compound_statement "{\n      *piVar1 = 0;\n    }" { (expression_statement "*piVar1 = 0;" (assignment_expression "*piVar1 = 0" (pointer_expression "*piVar1" * identifier) = number_literal) ;) }))) (expression_statement "FUN_0004dc98(param_1,piVar1);" (call_expression "FUN_0004dc98(param_1,piVar1)" identifier (argument_list "(param_1,piVar1)" ( identifier , identifier ))) ;) (return_statement "return (int *)0x0;" return (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) ;) })) (return_statement "return (int *)0x0;" return (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) ;) })))
(translation_unit "IdList * sqlite3IdListDup(sqlite3 *db,IdList *p)\n\n{\n  IdList *p_00;\n  IdList_item *pIVar1;\n  char *pcVar2;\n  IdList_item *pIVar3;\n  int iVar4;\n  undefined1 *puVar5;\n  undefined4 in_stack_ffffffdc;\n  \n  puVar5 = &_gp;\n  if ((p != (IdList *)0x0) && (db->mallocFailed == '\0')) {\n    p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));\n    if (p_00 != (IdList *)0x0) {\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }\n  }\n  return (IdList *)0x0;\n}\n\n" (function_definition "IdList * sqlite3IdListDup(sqlite3 *db,IdList *p)\n\n{\n  IdList *p_00;\n  IdList_item *pIVar1;\n  char *pcVar2;\n  IdList_item *pIVar3;\n  int iVar4;\n  undefined1 *puVar5;\n  undefined4 in_stack_ffffffdc;\n  \n  puVar5 = &_gp;\n  if ((p != (IdList *)0x0) && (db->mallocFailed == '\0')) {\n    p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));\n    if (p_00 != (IdList *)0x0) {\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }\n  }\n  return (IdList *)0x0;\n}" type_identifier (pointer_declarator "* sqlite3IdListDup(sqlite3 *db,IdList *p)" * (function_declarator "sqlite3IdListDup(sqlite3 *db,IdList *p)" identifier (parameter_list "(sqlite3 *db,IdList *p)" ( (parameter_declaration "sqlite3 *db" type_identifier (pointer_declarator "*db" * identifier)) , (parameter_declaration "IdList *p" type_identifier (pointer_declarator "*p" * identifier)) )))) (compound_statement "{\n  IdList *p_00;\n  IdList_item *pIVar1;\n  char *pcVar2;\n  IdList_item *pIVar3;\n  int iVar4;\n  undefined1 *puVar5;\n  undefined4 in_stack_ffffffdc;\n  \n  puVar5 = &_gp;\n  if ((p != (IdList *)0x0) && (db->mallocFailed == '\0')) {\n    p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));\n    if (p_00 != (IdList *)0x0) {\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }\n  }\n  return (IdList *)0x0;\n}" { (declaration "IdList *p_00;" type_identifier (pointer_declarator "*p_00" * identifier) ;) (declaration "IdList_item *pIVar1;" type_identifier (pointer_declarator "*pIVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (declaration "IdList_item *pIVar3;" type_identifier (pointer_declarator "*pIVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "undefined1 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "undefined4 in_stack_ffffffdc;" type_identifier identifier ;) (expression_statement "puVar5 = &_gp;" (assignment_expression "puVar5 = &_gp" identifier = (pointer_expression "&_gp" & identifier)) ;) (if_statement "if ((p != (IdList *)0x0) && (db->mallocFailed == '\0')) {\n    p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));\n    if (p_00 != (IdList *)0x0) {\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }\n  }" if (parenthesized_expression "((p != (IdList *)0x0) && (db->mallocFailed == '\0'))" ( (binary_expression "(p != (IdList *)0x0) && (db->mallocFailed == '\0')" (parenthesized_expression "(p != (IdList *)0x0)" ( (binary_expression "p != (IdList *)0x0" identifier != (cast_expression "(IdList *)0x0" ( (type_descriptor "IdList *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(db->mallocFailed == '\0')" ( (binary_expression "db->mallocFailed == '\0'" (field_expression "db->mallocFailed" identifier -> field_identifier) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n    p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));\n    if (p_00 != (IdList *)0x0) {\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }\n  }" { (expression_statement "p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc));" (assignment_expression "p_00 = (IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc))" identifier = (cast_expression "(IdList *)dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc))" ( (type_descriptor "IdList *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "dbMallocRawFinish(db,CONCAT44(&_gp,in_stack_ffffffdc))" identifier (argument_list "(db,CONCAT44(&_gp,in_stack_ffffffdc))" ( identifier , (call_expression "CONCAT44(&_gp,in_stack_ffffffdc)" identifier (argument_list "(&_gp,in_stack_ffffffdc)" ( (pointer_expression "&_gp" & identifier) , identifier ))) ))))) ;) (if_statement "if (p_00 != (IdList *)0x0) {\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }" if (parenthesized_expression "(p_00 != (IdList *)0x0)" ( (binary_expression "p_00 != (IdList *)0x0" identifier != (cast_expression "(IdList *)0x0" ( (type_descriptor "IdList *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      p_00->nId = p->nId;\n      if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }\n                    /* WARNING: Subroutine does not return */\n      sqlite3DbFreeNN(db,p_00);\n    }" { (expression_statement "p_00->nId = p->nId;" (assignment_expression "p_00->nId = p->nId" (field_expression "p_00->nId" identifier -> field_identifier) = (field_expression "p->nId" identifier -> field_identifier)) ;) (if_statement "if (db->mallocFailed == '\0') {\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }\n      else {\n        p_00->a = (IdList_item *)0x0;\n      }" if (parenthesized_expression "(db->mallocFailed == '\0')" ( (binary_expression "db->mallocFailed == '\0'" (field_expression "db->mallocFailed" identifier -> field_identifier) == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n        pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));\n        p_00->a = pIVar1;\n        if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }\n      }" { (expression_statement "pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc));" (assignment_expression "pIVar1 = (IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc))" identifier = (cast_expression "(IdList_item *)dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc))" ( (type_descriptor "IdList_item *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "dbMallocRawFinish(db,CONCAT44(puVar5,in_stack_ffffffdc))" identifier (argument_list "(db,CONCAT44(puVar5,in_stack_ffffffdc))" ( identifier , (call_expression "CONCAT44(puVar5,in_stack_ffffffdc)" identifier (argument_list "(puVar5,in_stack_ffffffdc)" ( identifier , identifier ))) ))))) ;) (expression_statement "p_00->a = pIVar1;" (assignment_expression "p_00->a = pIVar1" (field_expression "p_00->a" identifier -> field_identifier) = identifier) ;) (if_statement "if (pIVar1 != (IdList_item *)0x0) {\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }" if (parenthesized_expression "(pIVar1 != (IdList_item *)0x0)" ( (binary_expression "pIVar1 != (IdList_item *)0x0" identifier != (cast_expression "(IdList_item *)0x0" ( (type_descriptor "IdList_item *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }\n          return p_00;\n        }" { (if_statement "if (0 < p->nId) {\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }" if (parenthesized_expression "(0 < p->nId)" ( (binary_expression "0 < p->nId" number_literal < (field_expression "p->nId" identifier -> field_identifier)) )) (compound_statement "{\n            iVar4 = 0;\n            while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }\n          }" { (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n              pIVar1 = pIVar1 + iVar4;\n              pIVar3 = p->a + iVar4;\n              iVar4 = iVar4 + 1;\n              pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);\n              pIVar1->zName = pcVar2;\n              pIVar1->idx = pIVar3->idx;\n              if (p->nId <= iVar4) break;\n              pIVar1 = p_00->a;\n            }" { (expression_statement "pIVar1 = pIVar1 + iVar4;" (assignment_expression "pIVar1 = pIVar1 + iVar4" identifier = (binary_expression "pIVar1 + iVar4" identifier + identifier)) ;) (expression_statement "pIVar3 = p->a + iVar4;" (assignment_expression "pIVar3 = p->a + iVar4" identifier = (binary_expression "p->a + iVar4" (field_expression "p->a" identifier -> field_identifier) + identifier)) ;) (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) (expression_statement "pcVar2 = sqlite3DbStrDup(db,pIVar3->zName);" (assignment_expression "pcVar2 = sqlite3DbStrDup(db,pIVar3->zName)" identifier = (call_expression "sqlite3DbStrDup(db,pIVar3->zName)" identifier (argument_list "(db,pIVar3->zName)" ( identifier , (field_expression "pIVar3->zName" identifier -> field_identifier) )))) ;) (expression_statement "pIVar1->zName = pcVar2;" (assignment_expression "pIVar1->zName = pcVar2" (field_expression "pIVar1->zName" identifier -> field_identifier) = identifier) ;) (expression_statement "pIVar1->idx = pIVar3->idx;" (assignment_expression "pIVar1->idx = pIVar3->idx" (field_expression "pIVar1->idx" identifier -> field_identifier) = (field_expression "pIVar3->idx" identifier -> field_identifier)) ;) (if_statement "if (p->nId <= iVar4) break;" if (parenthesized_expression "(p->nId <= iVar4)" ( (binary_expression "p->nId <= iVar4" (field_expression "p->nId" identifier -> field_identifier) <= identifier) )) (break_statement "break;" break ;)) (expression_statement "pIVar1 = p_00->a;" (assignment_expression "pIVar1 = p_00->a" identifier = (field_expression "p_00->a" identifier -> field_identifier)) ;) })) })) (return_statement "return p_00;" return identifier ;) })) }) (else_clause "else {\n        p_00->a = (IdList_item *)0x0;\n      }" else (compound_statement "{\n        p_00->a = (IdList_item *)0x0;\n      }" { (expression_statement "p_00->a = (IdList_item *)0x0;" (assignment_expression "p_00->a = (IdList_item *)0x0" (field_expression "p_00->a" identifier -> field_identifier) = (cast_expression "(IdList_item *)0x0" ( (type_descriptor "IdList_item *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) }))) comment (expression_statement "sqlite3DbFreeNN(db,p_00);" (call_expression "sqlite3DbFreeNN(db,p_00)" identifier (argument_list "(db,p_00)" ( identifier , identifier ))) ;) })) })) (return_statement "return (IdList *)0x0;" return (cast_expression "(IdList *)0x0" ( (type_descriptor "IdList *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ;) })))
(translation_unit "int * FUN_00051a3c(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}\n\n" (function_definition "int * FUN_00051a3c(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}" primitive_type (pointer_declarator "* FUN_00051a3c(int param_1,int *param_2)" * (function_declarator "FUN_00051a3c(int param_1,int *param_2)" identifier (parameter_list "(int param_1,int *param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) )))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "undefined4 uVar3;" type_identifier identifier ;) (declaration "undefined4 *puVar4;" type_identifier (pointer_declarator "*puVar4" * identifier) ;) (declaration "undefined4 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (if_statement "if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }" if (parenthesized_expression "(((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0))" ( (binary_expression "((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)" (parenthesized_expression "((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0'))" ( (binary_expression "(param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')" (parenthesized_expression "(param_2 != (int *)0x0)" ( (binary_expression "param_2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*(char *)(param_1 + 0x51) == '\0')" ( (binary_expression "*(char *)(param_1 + 0x51) == '\0'" (pointer_expression "*(char *)(param_1 + 0x51)" * (cast_expression "(char *)(param_1 + 0x51)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x51)" ( (binary_expression "param_1 + 0x51" identifier + number_literal) )))) == (char_literal "'\0'" ' escape_sequence ')) ))) )) && (parenthesized_expression "(piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)" ( (comma_expression "piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0" (assignment_expression "piVar1 = (int *)FUN_00050854(param_1,param_2,0,8)" identifier = (cast_expression "(int *)FUN_00050854(param_1,param_2,0,8)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_00050854(param_1,param_2,0,8)" identifier (argument_list "(param_1,param_2,0,8)" ( identifier , identifier , number_literal , number_literal ))))) , (binary_expression "piVar1 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal))) ))) )) (compound_statement "{\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }" { (expression_statement "piVar1[1] = param_2[1];" (assignment_expression "piVar1[1] = param_2[1]" (subscript_expression "piVar1[1]" identifier [ number_literal ]) = (subscript_expression "param_2[1]" identifier [ number_literal ])) ;) (if_statement "if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }" if (parenthesized_expression "(*(char *)(param_1 + 0x51) == '\0')" ( (binary_expression "*(char *)(param_1 + 0x51) == '\0'" (pointer_expression "*(char *)(param_1 + 0x51)" * (cast_expression "(char *)(param_1 + 0x51)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x51)" ( (binary_expression "param_1 + 0x51" identifier + number_literal) )))) == (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }" { (expression_statement "iVar2 = FUN_00050854(param_1);" (assignment_expression "iVar2 = FUN_00050854(param_1)" identifier = (call_expression "FUN_00050854(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (expression_statement "*piVar1 = iVar2;" (assignment_expression "*piVar1 = iVar2" (pointer_expression "*piVar1" * identifier) = identifier) ;) (if_statement "if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }" if (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) (compound_statement "{\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }" { (if_statement "if (param_2[1] < 1) {\n          return piVar1;\n        }" if (parenthesized_expression "(param_2[1] < 1)" ( (binary_expression "param_2[1] < 1" (subscript_expression "param_2[1]" identifier [ number_literal ]) < number_literal) )) (compound_statement "{\n          return piVar1;\n        }" { (return_statement "return piVar1;" return identifier ;) })) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }" { (expression_statement "puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);" (assignment_expression "puVar4 = (undefined4 *)(iVar2 + iVar6 * 8)" identifier = (cast_expression "(undefined4 *)(iVar2 + iVar6 * 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar2 + iVar6 * 8)" ( (binary_expression "iVar2 + iVar6 * 8" identifier + (binary_expression "iVar6 * 8" identifier * number_literal)) )))) ;) (expression_statement "puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);" (assignment_expression "puVar5 = (undefined4 *)(*param_2 + iVar6 * 8)" identifier = (cast_expression "(undefined4 *)(*param_2 + iVar6 * 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_2 + iVar6 * 8)" ( (binary_expression "*param_2 + iVar6 * 8" (pointer_expression "*param_2" * identifier) + (binary_expression "iVar6 * 8" identifier * number_literal)) )))) ;) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "uVar3 = FUN_00050fc4(param_1,*puVar5);" (assignment_expression "uVar3 = FUN_00050fc4(param_1,*puVar5)" identifier = (call_expression "FUN_00050fc4(param_1,*puVar5)" identifier (argument_list "(param_1,*puVar5)" ( identifier , (pointer_expression "*puVar5" * identifier) )))) ;) (expression_statement "*puVar4 = uVar3;" (assignment_expression "*puVar4 = uVar3" (pointer_expression "*puVar4" * identifier) = identifier) ;) (expression_statement "puVar4[1] = puVar5[1];" (assignment_expression "puVar4[1] = puVar5[1]" (subscript_expression "puVar4[1]" identifier [ number_literal ]) = (subscript_expression "puVar5[1]" identifier [ number_literal ])) ;) (if_statement "if (param_2[1] <= iVar6) break;" if (parenthesized_expression "(param_2[1] <= iVar6)" ( (binary_expression "param_2[1] <= iVar6" (subscript_expression "param_2[1]" identifier [ number_literal ]) <= identifier) )) (break_statement "break;" break ;)) (expression_statement "iVar2 = *piVar1;" (assignment_expression "iVar2 = *piVar1" identifier = (pointer_expression "*piVar1" * identifier)) ;) })) (return_statement "return piVar1;" return identifier ;) })) }) (else_clause "else {\n      *piVar1 = 0;\n    }" else (compound_statement "{\n      *piVar1 = 0;\n    }" { (expression_statement "*piVar1 = 0;" (assignment_expression "*piVar1 = 0" (pointer_expression "*piVar1" * identifier) = number_literal) ;) }))) (expression_statement "FUN_0004dc98(param_1,piVar1);" (call_expression "FUN_0004dc98(param_1,piVar1)" identifier (argument_list "(param_1,piVar1)" ( identifier , identifier ))) ;) (return_statement "return (int *)0x0;" return (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) ;) })) (return_statement "return (int *)0x0;" return (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) )))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == (char_literal ' escape_sequence ')) ))) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , IDENT , LIT , LIT ))))) , (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT))) ))) )) (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (subscript_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) )))) == (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) < LIT) )) (compound_statement { (return_statement return IDENT ;) })) (expression_statement (assignment_expression IDENT = LIT) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression IDENT * LIT)) )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) + (binary_expression IDENT * LIT)) )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * IDENT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (subscript_expression IDENT [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) <= IDENT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) })) (return_statement return IDENT ;) })) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (return_statement return (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT) ;) })) (return_statement return (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT) ;) })))
(function_definition "int * FUN_00051a3c(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}" (primitive_type "int") (pointer_declarator "* FUN_00051a3c(int param_1,int *param_2)" (* "*") (function_declarator "FUN_00051a3c(int param_1,int *param_2)" (identifier "FUN_00051a3c") (parameter_list "(int param_1,int *param_2)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int *param_2" (primitive_type "int") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")")))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  undefined4 uVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  int iVar6;\n  \n  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }\n  return (int *)0x0;\n}" ({ "{") (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "undefined4 uVar3;" (type_identifier "undefined4") (identifier "uVar3") (; ";")) (declaration "undefined4 *puVar4;" (type_identifier "undefined4") (pointer_declarator "*puVar4" (* "*") (identifier "puVar4")) (; ";")) (declaration "undefined4 *puVar5;" (type_identifier "undefined4") (pointer_declarator "*puVar5" (* "*") (identifier "puVar5")) (; ";")) (declaration "int iVar6;" (primitive_type "int") (identifier "iVar6") (; ";")) (if_statement "if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }" (if "if") (parenthesized_expression "(((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0))" (( "(") (binary_expression "((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&\n     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)" (parenthesized_expression "((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0'))" (( "(") (binary_expression "(param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')" (parenthesized_expression "(param_2 != (int *)0x0)" (( "(") (binary_expression "param_2 != (int *)0x0" (identifier "param_2") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(*(char *)(param_1 + 0x51) == '\0')" (( "(") (binary_expression "*(char *)(param_1 + 0x51) == '\0'" (pointer_expression "*(char *)(param_1 + 0x51)" (* "*") (cast_expression "(char *)(param_1 + 0x51)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x51)" (( "(") (binary_expression "param_1 + 0x51" (identifier "param_1") (+ "+") (number_literal "0x51")) () ")")))) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")"))) () ")")) (&& "&&") (parenthesized_expression "(piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)" (( "(") (comma_expression "piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0" (assignment_expression "piVar1 = (int *)FUN_00050854(param_1,param_2,0,8)" (identifier "piVar1") (= "=") (cast_expression "(int *)FUN_00050854(param_1,param_2,0,8)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_00050854(param_1,param_2,0,8)" (identifier "FUN_00050854") (argument_list "(param_1,param_2,0,8)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (number_literal "0") (, ",") (number_literal "8") () ")"))))) (, ",") (binary_expression "piVar1 != (int *)0x0" (identifier "piVar1") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0")))) () ")"))) () ")")) (compound_statement "{\n    piVar1[1] = param_2[1];\n    if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }\n    FUN_0004dc98(param_1,piVar1);\n    return (int *)0x0;\n  }" ({ "{") (expression_statement "piVar1[1] = param_2[1];" (assignment_expression "piVar1[1] = param_2[1]" (subscript_expression "piVar1[1]" (identifier "piVar1") ([ "[") (number_literal "1") (] "]")) (= "=") (subscript_expression "param_2[1]" (identifier "param_2") ([ "[") (number_literal "1") (] "]"))) (; ";")) (if_statement "if (*(char *)(param_1 + 0x51) == '\0') {\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }\n    else {\n      *piVar1 = 0;\n    }" (if "if") (parenthesized_expression "(*(char *)(param_1 + 0x51) == '\0')" (( "(") (binary_expression "*(char *)(param_1 + 0x51) == '\0'" (pointer_expression "*(char *)(param_1 + 0x51)" (* "*") (cast_expression "(char *)(param_1 + 0x51)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x51)" (( "(") (binary_expression "param_1 + 0x51" (identifier "param_1") (+ "+") (number_literal "0x51")) () ")")))) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n      iVar2 = FUN_00050854(param_1);\n      *piVar1 = iVar2;\n      if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }\n    }" ({ "{") (expression_statement "iVar2 = FUN_00050854(param_1);" (assignment_expression "iVar2 = FUN_00050854(param_1)" (identifier "iVar2") (= "=") (call_expression "FUN_00050854(param_1)" (identifier "FUN_00050854") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (; ";")) (expression_statement "*piVar1 = iVar2;" (assignment_expression "*piVar1 = iVar2" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (= "=") (identifier "iVar2")) (; ";")) (if_statement "if (iVar2 != 0) {\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }" (if "if") (parenthesized_expression "(iVar2 != 0)" (( "(") (binary_expression "iVar2 != 0" (identifier "iVar2") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        if (param_2[1] < 1) {\n          return piVar1;\n        }\n        iVar6 = 0;\n        while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }\n        return piVar1;\n      }" ({ "{") (if_statement "if (param_2[1] < 1) {\n          return piVar1;\n        }" (if "if") (parenthesized_expression "(param_2[1] < 1)" (( "(") (binary_expression "param_2[1] < 1" (subscript_expression "param_2[1]" (identifier "param_2") ([ "[") (number_literal "1") (] "]")) (< "<") (number_literal "1")) () ")")) (compound_statement "{\n          return piVar1;\n        }" ({ "{") (return_statement "return piVar1;" (return "return") (identifier "piVar1") (; ";")) (} "}"))) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" (identifier "iVar6") (= "=") (number_literal "0")) (; ";")) (while_statement "while( true ) {\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);\n          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);\n          iVar6 = iVar6 + 1;\n          uVar3 = FUN_00050fc4(param_1,*puVar5);\n          *puVar4 = uVar3;\n          puVar4[1] = puVar5[1];\n          if (param_2[1] <= iVar6) break;\n          iVar2 = *piVar1;\n        }" ({ "{") (expression_statement "puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);" (assignment_expression "puVar4 = (undefined4 *)(iVar2 + iVar6 * 8)" (identifier "puVar4") (= "=") (cast_expression "(undefined4 *)(iVar2 + iVar6 * 8)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar2 + iVar6 * 8)" (( "(") (binary_expression "iVar2 + iVar6 * 8" (identifier "iVar2") (+ "+") (binary_expression "iVar6 * 8" (identifier "iVar6") (* "*") (number_literal "8"))) () ")")))) (; ";")) (expression_statement "puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);" (assignment_expression "puVar5 = (undefined4 *)(*param_2 + iVar6 * 8)" (identifier "puVar5") (= "=") (cast_expression "(undefined4 *)(*param_2 + iVar6 * 8)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*param_2 + iVar6 * 8)" (( "(") (binary_expression "*param_2 + iVar6 * 8" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (+ "+") (binary_expression "iVar6 * 8" (identifier "iVar6") (* "*") (number_literal "8"))) () ")")))) (; ";")) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" (identifier "iVar6") (= "=") (binary_expression "iVar6 + 1" (identifier "iVar6") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "uVar3 = FUN_00050fc4(param_1,*puVar5);" (assignment_expression "uVar3 = FUN_00050fc4(param_1,*puVar5)" (identifier "uVar3") (= "=") (call_expression "FUN_00050fc4(param_1,*puVar5)" (identifier "FUN_00050fc4") (argument_list "(param_1,*puVar5)" (( "(") (identifier "param_1") (, ",") (pointer_expression "*puVar5" (* "*") (identifier "puVar5")) () ")")))) (; ";")) (expression_statement "*puVar4 = uVar3;" (assignment_expression "*puVar4 = uVar3" (pointer_expression "*puVar4" (* "*") (identifier "puVar4")) (= "=") (identifier "uVar3")) (; ";")) (expression_statement "puVar4[1] = puVar5[1];" (assignment_expression "puVar4[1] = puVar5[1]" (subscript_expression "puVar4[1]" (identifier "puVar4") ([ "[") (number_literal "1") (] "]")) (= "=") (subscript_expression "puVar5[1]" (identifier "puVar5") ([ "[") (number_literal "1") (] "]"))) (; ";")) (if_statement "if (param_2[1] <= iVar6) break;" (if "if") (parenthesized_expression "(param_2[1] <= iVar6)" (( "(") (binary_expression "param_2[1] <= iVar6" (subscript_expression "param_2[1]" (identifier "param_2") ([ "[") (number_literal "1") (] "]")) (<= "<=") (identifier "iVar6")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar2 = *piVar1;" (assignment_expression "iVar2 = *piVar1" (identifier "iVar2") (= "=") (pointer_expression "*piVar1" (* "*") (identifier "piVar1"))) (; ";")) (} "}"))) (return_statement "return piVar1;" (return "return") (identifier "piVar1") (; ";")) (} "}"))) (} "}")) (else_clause "else {\n      *piVar1 = 0;\n    }" (else "else") (compound_statement "{\n      *piVar1 = 0;\n    }" ({ "{") (expression_statement "*piVar1 = 0;" (assignment_expression "*piVar1 = 0" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (= "=") (number_literal "0")) (; ";")) (} "}")))) (expression_statement "FUN_0004dc98(param_1,piVar1);" (call_expression "FUN_0004dc98(param_1,piVar1)" (identifier "FUN_0004dc98") (argument_list "(param_1,piVar1)" (( "(") (identifier "param_1") (, ",") (identifier "piVar1") () ")"))) (; ";")) (return_statement "return (int *)0x0;" (return "return") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0")) (; ";")) (} "}"))) (return_statement "return (int *)0x0;" (return "return") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0")) (; ";")) (} "}")))
(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: (pointer_declarator declarator: (identifier)))))) body: (compound_statement (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (if_statement condition: (parenthesized_expression (binary_expression left: (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: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (char_literal (escape_sequence)))))) right: (parenthesized_expression (comma_expression left: (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) (identifier) (number_literal) (number_literal))))) right: (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: (subscript_expression argument: (identifier) index: (number_literal)) right: (subscript_expression argument: (identifier) index: (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: (char_literal (escape_sequence)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (pointer_expression argument: (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: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) consequence: (compound_statement (return_statement (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (while_statement condition: (parenthesized_expression (true)) body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (subscript_expression argument: (identifier) index: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))))) (return_statement (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (number_literal)))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))) (return_statement (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal))))) (return_statement (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal))))))

int * MASKED(int param_1,int *param_2)

{
  int *piVar1;
  int iVar2;
  undefined4 uVar3;
  undefined4 *puVar4;
  undefined4 *puVar5;
  int iVar6;
  
  if (((param_2 != (int *)0x0) && (*(char *)(param_1 + 0x51) == '\0')) &&
     (piVar1 = (int *)FUN_00050854(param_1,param_2,0,8), piVar1 != (int *)0x0)) {
    piVar1[1] = param_2[1];
    if (*(char *)(param_1 + 0x51) == '\0') {
      iVar2 = FUN_00050854(param_1);
      *piVar1 = iVar2;
      if (iVar2 != 0) {
        if (param_2[1] < 1) {
          return piVar1;
        }
        iVar6 = 0;
        while( true ) {
          puVar4 = (undefined4 *)(iVar2 + iVar6 * 8);
          puVar5 = (undefined4 *)(*param_2 + iVar6 * 8);
          iVar6 = iVar6 + 1;
          uVar3 = FUN_00050fc4(param_1,*puVar5);
          *puVar4 = uVar3;
          puVar4[1] = puVar5[1];
          if (param_2[1] <= iVar6) break;
          iVar2 = *piVar1;
        }
        return piVar1;
      }
    }
    else {
      *piVar1 = 0;
    }
    FUN_0004dc98(param_1,piVar1);
    return (int *)0x0;
  }
  return (int *)0x0;
}

