
int ask_and_unlink(char *dest,int flags)

{
  int iVar1;
  int iVar2;
  int *piVar3;
  
  if ((flags & 0x18U) == 0) {
    (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);
    iVar1 = -1;
  }
  else {
    piVar3 = *(int **)PTR_bb_errno_001311d8;
    iVar1 = *piVar3;
    if ((flags & 0x10U) != 0) {
      (*(code *)PTR___fprintf_chk_00131d28)
                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,
                 *(undefined4 *)PTR_applet_name_001311ac,dest);
      iVar2 = bb_ask_y_confirmation();
      if (iVar2 == 0) {
        return 0;
      }
    }
    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);
    if (iVar2 < 0) {
      if ((*piVar3 == iVar1) && (iVar1 == 2)) {
        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);
        iVar1 = -1;
      }
      else {
        *piVar3 = iVar1;
        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);
        iVar1 = -1;
      }
    }
    else {
      iVar1 = 1;
      if ((flags & 0x9000U) == 0x9000) {
        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);
        iVar1 = 1;
      }
    }
  }
  return iVar1;
}



undefined4 FUN_000ede94(undefined4 param_1,uint param_2)

{
  undefined4 uVar1;
  int iVar2;
  int *piVar3;
  int iVar4;
  
  if ((param_2 & 0x18) == 0) {
    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);
    uVar1 = 0xffffffff;
  }
  else {
    piVar3 = *(int **)PTR_DAT_001311d8;
    iVar4 = *piVar3;
    if ((param_2 & 0x10) != 0) {
      (*(code *)PTR___fprintf_chk_00131d28)
                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,
                 *(undefined4 *)PTR_DAT_001311ac,param_1);
      iVar2 = FUN_000ecf64();
      if (iVar2 == 0) {
        return 0;
      }
    }
    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);
    if (iVar2 < 0) {
      if ((*piVar3 == iVar4) && (iVar4 == 2)) {
        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);
        uVar1 = 0xffffffff;
      }
      else {
        *piVar3 = iVar4;
        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);
        uVar1 = 0xffffffff;
      }
    }
    else {
      uVar1 = 1;
      if ((param_2 & 0x9000) == 0x9000) {
        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);
        uVar1 = 1;
      }
    }
  }
  return uVar1;
}


lui gp,0x5
addiu gp,gp,-0x4d44
addu gp,gp,t9
addiu sp,sp,-0x38
sw ra,0x34(sp)
sw s3,0x30(sp)
sw s2,0x2c(sp)
sw s1,0x28(sp)
sw s0,0x24(sp)
sw gp,0x18(sp)
andi v0,a1,0x18
bne v0,zero,0x000edf04
_or s0,a0,zero
or a1,a0,zero
lw a0,-0x7fac(gp)
addiu a0,a0,-0x6fc0
lw t9,-0x7f04(gp)
jalr t9
_nop
lw gp,0x18(sp)
li v0,-0x1
lw ra,0x34(sp)
lw s3,0x30(sp)
lw s2,0x2c(sp)
lw s1,0x28(sp)
lw s0,0x24(sp)
jr ra
_addiu sp,sp,0x38
or s1,a1,zero
lw v0,-0x7f78(gp)
lw s2,0x0(v0)
andi v0,a1,0x10
beq v0,zero,0x000edf64
_lw s3,0x0(s2)
sw a0,0x10(sp)
lw v0,-0x7fa4(gp)
lw a3,0x0(v0)
lw a2,-0x7fac(gp)
addiu a2,a2,0x5814
li a1,0x1
lw v0,-0x6fb4(gp)
lw a0,0x0(v0)
lw t9,-0x7428(gp)
jalr t9
_nop
lw gp,0x18(sp)
lw t9,-0x7d7c(gp)
bal 0x000ecf64
_nop
lw gp,0x18(sp)
beq v0,zero,0x000edeec
_lw ra,0x34(sp)
or a0,s0,zero
lw t9,-0x70a8(gp)
jalr t9
_nop
lw gp,0x18(sp)
bgez v0,0x000edfe0
_ori v1,zero,0x9000
lw v0,0x0(s2)
bne v0,s3,0x000edfb8
_nop
li v0,0x2
bne s3,v0,0x000edfb8
_or a1,s0,zero
lw a0,-0x7fac(gp)
addiu a0,a0,0x582c
lw t9,-0x7f80(gp)
jalr t9
_nop
lw gp,0x18(sp)
b 0x000edee8
_li v0,-0x1
sw s3,0x0(s2)
or a1,s0,zero
lw a0,-0x7fac(gp)
addiu a0,a0,-0x6fc0
lw t9,-0x7f04(gp)
jalr t9
_nop
lw gp,0x18(sp)
b 0x000edee8
_li v0,-0x1
andi s1,s1,0x9000
bne s1,v1,0x000edee8
_li v0,0x1
or a2,s0,zero
lw a1,-0x7fac(gp)
addiu a1,a1,0x5854
li a0,0x1
lw t9,-0x7304(gp)
jalr t9
_nop
lw gp,0x18(sp)
b 0x000edee8
_li v0,0x1
(translation_unit "undefined4 FUN_000ede94(undefined4 param_1,uint param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}\n\n" (function_definition "undefined4 FUN_000ede94(undefined4 param_1,uint param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}" type_identifier (function_declarator "FUN_000ede94(undefined4 param_1,uint param_2)" identifier (parameter_list "(undefined4 param_1,uint param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (if_statement "if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" if (parenthesized_expression "((param_2 & 0x18) == 0)" ( (binary_expression "(param_2 & 0x18) == 0" (parenthesized_expression "(param_2 & 0x18)" ( (binary_expression "param_2 & 0x18" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }" { (expression_statement "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);" (call_expression "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_0013124c)" ( (pointer_expression "*(code *)PTR_FUN_0013124c" * (cast_expression "(code *)PTR_FUN_0013124c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_FUN_001311a4 + -0x6fc0,param_1)" ( (binary_expression "PTR_FUN_001311a4 + -0x6fc0" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" identifier = number_literal) ;) }) (else_clause "else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" else (compound_statement "{\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" { (expression_statement "piVar3 = *(int **)PTR_DAT_001311d8;" (assignment_expression "piVar3 = *(int **)PTR_DAT_001311d8" identifier = (pointer_expression "*(int **)PTR_DAT_001311d8" * (cast_expression "(int **)PTR_DAT_001311d8" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (expression_statement "iVar4 = *piVar3;" (assignment_expression "iVar4 = *piVar3" identifier = (pointer_expression "*piVar3" * identifier)) ;) (if_statement "if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" if (parenthesized_expression "((param_2 & 0x10) != 0)" ( (binary_expression "(param_2 & 0x10) != 0" (parenthesized_expression "(param_2 & 0x10)" ( (binary_expression "param_2 & 0x10" identifier & number_literal) )) != number_literal) )) (compound_statement "{\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" { (expression_statement "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);" (call_expression "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1)" (parenthesized_expression "(*(code *)PTR___fprintf_chk_00131d28)" ( (pointer_expression "*(code *)PTR___fprintf_chk_00131d28" * (cast_expression "(code *)PTR___fprintf_chk_00131d28" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1)" ( (pointer_expression "*(undefined4 *)PTR_stderr_0013219c" * (cast_expression "(undefined4 *)PTR_stderr_0013219c" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , number_literal , (binary_expression "PTR_FUN_001311a4 + 0x5814" identifier + number_literal) , (pointer_expression "*(undefined4 *)PTR_DAT_001311ac" * (cast_expression "(undefined4 *)PTR_DAT_001311ac" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , identifier ))) ;) (expression_statement "iVar2 = FUN_000ecf64();" (assignment_expression "iVar2 = FUN_000ecf64()" identifier = (call_expression "FUN_000ecf64()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar2 == 0) {\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) })) (expression_statement "iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);" (assignment_expression "iVar2 = (*(code *)PTR_unlink_001320a8)(param_1)" identifier = (call_expression "(*(code *)PTR_unlink_001320a8)(param_1)" (parenthesized_expression "(*(code *)PTR_unlink_001320a8)" ( (pointer_expression "*(code *)PTR_unlink_001320a8" * (cast_expression "(code *)PTR_unlink_001320a8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1)" ( identifier )))) ;) (if_statement "if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }" { (if_statement "if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" if (parenthesized_expression "((*piVar3 == iVar4) && (iVar4 == 2))" ( (binary_expression "(*piVar3 == iVar4) && (iVar4 == 2)" (parenthesized_expression "(*piVar3 == iVar4)" ( (binary_expression "*piVar3 == iVar4" (pointer_expression "*piVar3" * identifier) == identifier) )) && (parenthesized_expression "(iVar4 == 2)" ( (binary_expression "iVar4 == 2" identifier == number_literal) ))) )) (compound_statement "{\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }" { (expression_statement "(*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);" (call_expression "(*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_001311d0)" ( (pointer_expression "*(code *)PTR_FUN_001311d0" * (cast_expression "(code *)PTR_FUN_001311d0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_FUN_001311a4 + 0x582c,param_1)" ( (binary_expression "PTR_FUN_001311a4 + 0x582c" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" identifier = number_literal) ;) }) (else_clause "else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" else (compound_statement "{\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" { (expression_statement "*piVar3 = iVar4;" (assignment_expression "*piVar3 = iVar4" (pointer_expression "*piVar3" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);" (call_expression "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_0013124c)" ( (pointer_expression "*(code *)PTR_FUN_0013124c" * (cast_expression "(code *)PTR_FUN_0013124c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_FUN_001311a4 + -0x6fc0,param_1)" ( (binary_expression "PTR_FUN_001311a4 + -0x6fc0" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" identifier = number_literal) ;) }))) }) (else_clause "else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" else (compound_statement "{\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" { (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" identifier = number_literal) ;) (if_statement "if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }" if (parenthesized_expression "((param_2 & 0x9000) == 0x9000)" ( (binary_expression "(param_2 & 0x9000) == 0x9000" (parenthesized_expression "(param_2 & 0x9000)" ( (binary_expression "param_2 & 0x9000" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }" { (expression_statement "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);" (call_expression "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1)" (parenthesized_expression "(*(code *)PTR___printf_chk_00131e4c)" ( (pointer_expression "*(code *)PTR___printf_chk_00131e4c" * (cast_expression "(code *)PTR___printf_chk_00131e4c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(1,PTR_FUN_001311a4 + 0x5854,param_1)" ( number_literal , (binary_expression "PTR_FUN_001311a4 + 0x5854" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" identifier = number_literal) ;) })) }))) }))) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit "int ask_and_unlink(char *dest,int flags)\n\n{\n  int iVar1;\n  int iVar2;\n  int *piVar3;\n  \n  if ((flags & 0x18U) == 0) {\n    (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n    iVar1 = -1;\n  }\n  else {\n    piVar3 = *(int **)PTR_bb_errno_001311d8;\n    iVar1 = *piVar3;\n    if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }\n  }\n  return iVar1;\n}\n\n" (function_definition "int ask_and_unlink(char *dest,int flags)\n\n{\n  int iVar1;\n  int iVar2;\n  int *piVar3;\n  \n  if ((flags & 0x18U) == 0) {\n    (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n    iVar1 = -1;\n  }\n  else {\n    piVar3 = *(int **)PTR_bb_errno_001311d8;\n    iVar1 = *piVar3;\n    if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }\n  }\n  return iVar1;\n}" primitive_type (function_declarator "ask_and_unlink(char *dest,int flags)" identifier (parameter_list "(char *dest,int flags)" ( (parameter_declaration "char *dest" primitive_type (pointer_declarator "*dest" * identifier)) , (parameter_declaration "int flags" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int *piVar3;\n  \n  if ((flags & 0x18U) == 0) {\n    (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n    iVar1 = -1;\n  }\n  else {\n    piVar3 = *(int **)PTR_bb_errno_001311d8;\n    iVar1 = *piVar3;\n    if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }\n  }\n  return iVar1;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (if_statement "if ((flags & 0x18U) == 0) {\n    (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n    iVar1 = -1;\n  }\n  else {\n    piVar3 = *(int **)PTR_bb_errno_001311d8;\n    iVar1 = *piVar3;\n    if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }\n  }" if (parenthesized_expression "((flags & 0x18U) == 0)" ( (binary_expression "(flags & 0x18U) == 0" (parenthesized_expression "(flags & 0x18U)" ( (binary_expression "flags & 0x18U" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n    iVar1 = -1;\n  }" { (expression_statement "(*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);" (call_expression "(*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest)" (parenthesized_expression "(*(code *)PTR_bb_perror_msg_0013124c)" ( (pointer_expression "*(code *)PTR_bb_perror_msg_0013124c" * (cast_expression "(code *)PTR_bb_perror_msg_0013124c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest)" ( (binary_expression "PTR_bdcommands_4__name_4__001311a4 + -0x6fc0" identifier + number_literal) , identifier ))) ;) (expression_statement "iVar1 = -1;" (assignment_expression "iVar1 = -1" identifier = number_literal) ;) }) (else_clause "else {\n    piVar3 = *(int **)PTR_bb_errno_001311d8;\n    iVar1 = *piVar3;\n    if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }\n  }" else (compound_statement "{\n    piVar3 = *(int **)PTR_bb_errno_001311d8;\n    iVar1 = *piVar3;\n    if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(dest);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }\n  }" { (expression_statement "piVar3 = *(int **)PTR_bb_errno_001311d8;" (assignment_expression "piVar3 = *(int **)PTR_bb_errno_001311d8" identifier = (pointer_expression "*(int **)PTR_bb_errno_001311d8" * (cast_expression "(int **)PTR_bb_errno_001311d8" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (expression_statement "iVar1 = *piVar3;" (assignment_expression "iVar1 = *piVar3" identifier = (pointer_expression "*piVar3" * identifier)) ;) (if_statement "if ((flags & 0x10U) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" if (parenthesized_expression "((flags & 0x10U) != 0)" ( (binary_expression "(flags & 0x10U) != 0" (parenthesized_expression "(flags & 0x10U)" ( (binary_expression "flags & 0x10U" identifier & number_literal) )) != number_literal) )) (compound_statement "{\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);\n      iVar2 = bb_ask_y_confirmation();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" { (expression_statement "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest);" (call_expression "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest)" (parenthesized_expression "(*(code *)PTR___fprintf_chk_00131d28)" ( (pointer_expression "*(code *)PTR___fprintf_chk_00131d28" * (cast_expression "(code *)PTR___fprintf_chk_00131d28" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)PTR_stderr_0013219c,1,PTR_bdcommands_4__name_4__001311a4 + 0x5814,\n                 *(undefined4 *)PTR_applet_name_001311ac,dest)" ( (pointer_expression "*(undefined4 *)PTR_stderr_0013219c" * (cast_expression "(undefined4 *)PTR_stderr_0013219c" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , number_literal , (binary_expression "PTR_bdcommands_4__name_4__001311a4 + 0x5814" identifier + number_literal) , (pointer_expression "*(undefined4 *)PTR_applet_name_001311ac" * (cast_expression "(undefined4 *)PTR_applet_name_001311ac" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , identifier ))) ;) (expression_statement "iVar2 = bb_ask_y_confirmation();" (assignment_expression "iVar2 = bb_ask_y_confirmation()" identifier = (call_expression "bb_ask_y_confirmation()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar2 == 0) {\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) })) (expression_statement "iVar2 = (*(code *)PTR_unlink_001320a8)(dest);" (assignment_expression "iVar2 = (*(code *)PTR_unlink_001320a8)(dest)" identifier = (call_expression "(*(code *)PTR_unlink_001320a8)(dest)" (parenthesized_expression "(*(code *)PTR_unlink_001320a8)" ( (pointer_expression "*(code *)PTR_unlink_001320a8" * (cast_expression "(code *)PTR_unlink_001320a8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(dest)" ( identifier )))) ;) (if_statement "if (iVar2 < 0) {\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }\n    else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n      if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }\n    }" { (if_statement "if ((*piVar3 == iVar1) && (iVar1 == 2)) {\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }\n      else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }" if (parenthesized_expression "((*piVar3 == iVar1) && (iVar1 == 2))" ( (binary_expression "(*piVar3 == iVar1) && (iVar1 == 2)" (parenthesized_expression "(*piVar3 == iVar1)" ( (binary_expression "*piVar3 == iVar1" (pointer_expression "*piVar3" * identifier) == identifier) )) && (parenthesized_expression "(iVar1 == 2)" ( (binary_expression "iVar1 == 2" identifier == number_literal) ))) )) (compound_statement "{\n        (*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);\n        iVar1 = -1;\n      }" { (expression_statement "(*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest);" (call_expression "(*(code *)PTR_bb_error_msg_001311d0)(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest)" (parenthesized_expression "(*(code *)PTR_bb_error_msg_001311d0)" ( (pointer_expression "*(code *)PTR_bb_error_msg_001311d0" * (cast_expression "(code *)PTR_bb_error_msg_001311d0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_bdcommands_4__name_4__001311a4 + 0x582c,dest)" ( (binary_expression "PTR_bdcommands_4__name_4__001311a4 + 0x582c" identifier + number_literal) , identifier ))) ;) (expression_statement "iVar1 = -1;" (assignment_expression "iVar1 = -1" identifier = number_literal) ;) }) (else_clause "else {\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }" else (compound_statement "{\n        *piVar3 = iVar1;\n        (*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);\n        iVar1 = -1;\n      }" { (expression_statement "*piVar3 = iVar1;" (assignment_expression "*piVar3 = iVar1" (pointer_expression "*piVar3" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest);" (call_expression "(*(code *)PTR_bb_perror_msg_0013124c)(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest)" (parenthesized_expression "(*(code *)PTR_bb_perror_msg_0013124c)" ( (pointer_expression "*(code *)PTR_bb_perror_msg_0013124c" * (cast_expression "(code *)PTR_bb_perror_msg_0013124c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_bdcommands_4__name_4__001311a4 + -0x6fc0,dest)" ( (binary_expression "PTR_bdcommands_4__name_4__001311a4 + -0x6fc0" identifier + number_literal) , identifier ))) ;) (expression_statement "iVar1 = -1;" (assignment_expression "iVar1 = -1" identifier = number_literal) ;) }))) }) (else_clause "else {\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }" else (compound_statement "{\n      iVar1 = 1;\n      if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }\n    }" { (expression_statement "iVar1 = 1;" (assignment_expression "iVar1 = 1" identifier = number_literal) ;) (if_statement "if ((flags & 0x9000U) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }" if (parenthesized_expression "((flags & 0x9000U) == 0x9000)" ( (binary_expression "(flags & 0x9000U) == 0x9000" (parenthesized_expression "(flags & 0x9000U)" ( (binary_expression "flags & 0x9000U" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);\n        iVar1 = 1;\n      }" { (expression_statement "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest);" (call_expression "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest)" (parenthesized_expression "(*(code *)PTR___printf_chk_00131e4c)" ( (pointer_expression "*(code *)PTR___printf_chk_00131e4c" * (cast_expression "(code *)PTR___printf_chk_00131e4c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(1,PTR_bdcommands_4__name_4__001311a4 + 0x5854,dest)" ( number_literal , (binary_expression "PTR_bdcommands_4__name_4__001311a4 + 0x5854" identifier + number_literal) , identifier ))) ;) (expression_statement "iVar1 = 1;" (assignment_expression "iVar1 = 1" identifier = number_literal) ;) })) }))) }))) (return_statement "return iVar1;" return identifier ;) })))
(translation_unit "undefined4 FUN_000ede94(undefined4 param_1,uint param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}\n\n" (function_definition "undefined4 FUN_000ede94(undefined4 param_1,uint param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}" type_identifier (function_declarator "FUN_000ede94(undefined4 param_1,uint param_2)" identifier (parameter_list "(undefined4 param_1,uint param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "uint param_2" type_identifier identifier) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (if_statement "if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" if (parenthesized_expression "((param_2 & 0x18) == 0)" ( (binary_expression "(param_2 & 0x18) == 0" (parenthesized_expression "(param_2 & 0x18)" ( (binary_expression "param_2 & 0x18" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }" { (expression_statement "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);" (call_expression "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_0013124c)" ( (pointer_expression "*(code *)PTR_FUN_0013124c" * (cast_expression "(code *)PTR_FUN_0013124c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_FUN_001311a4 + -0x6fc0,param_1)" ( (binary_expression "PTR_FUN_001311a4 + -0x6fc0" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" identifier = number_literal) ;) }) (else_clause "else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" else (compound_statement "{\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" { (expression_statement "piVar3 = *(int **)PTR_DAT_001311d8;" (assignment_expression "piVar3 = *(int **)PTR_DAT_001311d8" identifier = (pointer_expression "*(int **)PTR_DAT_001311d8" * (cast_expression "(int **)PTR_DAT_001311d8" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (expression_statement "iVar4 = *piVar3;" (assignment_expression "iVar4 = *piVar3" identifier = (pointer_expression "*piVar3" * identifier)) ;) (if_statement "if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" if (parenthesized_expression "((param_2 & 0x10) != 0)" ( (binary_expression "(param_2 & 0x10) != 0" (parenthesized_expression "(param_2 & 0x10)" ( (binary_expression "param_2 & 0x10" identifier & number_literal) )) != number_literal) )) (compound_statement "{\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" { (expression_statement "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);" (call_expression "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1)" (parenthesized_expression "(*(code *)PTR___fprintf_chk_00131d28)" ( (pointer_expression "*(code *)PTR___fprintf_chk_00131d28" * (cast_expression "(code *)PTR___fprintf_chk_00131d28" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1)" ( (pointer_expression "*(undefined4 *)PTR_stderr_0013219c" * (cast_expression "(undefined4 *)PTR_stderr_0013219c" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , number_literal , (binary_expression "PTR_FUN_001311a4 + 0x5814" identifier + number_literal) , (pointer_expression "*(undefined4 *)PTR_DAT_001311ac" * (cast_expression "(undefined4 *)PTR_DAT_001311ac" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) , identifier ))) ;) (expression_statement "iVar2 = FUN_000ecf64();" (assignment_expression "iVar2 = FUN_000ecf64()" identifier = (call_expression "FUN_000ecf64()" identifier (argument_list "()" ( )))) ;) (if_statement "if (iVar2 == 0) {\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) })) (expression_statement "iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);" (assignment_expression "iVar2 = (*(code *)PTR_unlink_001320a8)(param_1)" identifier = (call_expression "(*(code *)PTR_unlink_001320a8)(param_1)" (parenthesized_expression "(*(code *)PTR_unlink_001320a8)" ( (pointer_expression "*(code *)PTR_unlink_001320a8" * (cast_expression "(code *)PTR_unlink_001320a8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1)" ( identifier )))) ;) (if_statement "if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }" { (if_statement "if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" if (parenthesized_expression "((*piVar3 == iVar4) && (iVar4 == 2))" ( (binary_expression "(*piVar3 == iVar4) && (iVar4 == 2)" (parenthesized_expression "(*piVar3 == iVar4)" ( (binary_expression "*piVar3 == iVar4" (pointer_expression "*piVar3" * identifier) == identifier) )) && (parenthesized_expression "(iVar4 == 2)" ( (binary_expression "iVar4 == 2" identifier == number_literal) ))) )) (compound_statement "{\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }" { (expression_statement "(*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);" (call_expression "(*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_001311d0)" ( (pointer_expression "*(code *)PTR_FUN_001311d0" * (cast_expression "(code *)PTR_FUN_001311d0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_FUN_001311a4 + 0x582c,param_1)" ( (binary_expression "PTR_FUN_001311a4 + 0x582c" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" identifier = number_literal) ;) }) (else_clause "else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" else (compound_statement "{\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" { (expression_statement "*piVar3 = iVar4;" (assignment_expression "*piVar3 = iVar4" (pointer_expression "*piVar3" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);" (call_expression "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_0013124c)" ( (pointer_expression "*(code *)PTR_FUN_0013124c" * (cast_expression "(code *)PTR_FUN_0013124c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_FUN_001311a4 + -0x6fc0,param_1)" ( (binary_expression "PTR_FUN_001311a4 + -0x6fc0" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" identifier = number_literal) ;) }))) }) (else_clause "else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" else (compound_statement "{\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" { (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" identifier = number_literal) ;) (if_statement "if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }" if (parenthesized_expression "((param_2 & 0x9000) == 0x9000)" ( (binary_expression "(param_2 & 0x9000) == 0x9000" (parenthesized_expression "(param_2 & 0x9000)" ( (binary_expression "param_2 & 0x9000" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }" { (expression_statement "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);" (call_expression "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1)" (parenthesized_expression "(*(code *)PTR___printf_chk_00131e4c)" ( (pointer_expression "*(code *)PTR___printf_chk_00131e4c" * (cast_expression "(code *)PTR___printf_chk_00131e4c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(1,PTR_FUN_001311a4 + 0x5854,param_1)" ( number_literal , (binary_expression "PTR_FUN_001311a4 + 0x5854" identifier + number_literal) , identifier ))) ;) (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" identifier = number_literal) ;) })) }))) }))) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) IDENT))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) != LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) , LIT , (binary_expression IDENT + LIT) , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (return_statement return LIT ;) })) })) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( 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 * IDENT) == IDENT) )) && (parenthesized_expression ( (binary_expression IDENT == LIT) ))) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }))) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( LIT , (binary_expression IDENT + LIT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) })) }))) }))) (return_statement return IDENT ;) })))
(function_definition "undefined4 FUN_000ede94(undefined4 param_1,uint param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}" (type_identifier "undefined4") (function_declarator "FUN_000ede94(undefined4 param_1,uint param_2)" (identifier "FUN_000ede94") (parameter_list "(undefined4 param_1,uint param_2)" (( "(") (parameter_declaration "undefined4 param_1" (type_identifier "undefined4") (identifier "param_1")) (, ",") (parameter_declaration "uint param_2" (type_identifier "uint") (identifier "param_2")) () ")"))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  int *piVar3;\n  int iVar4;\n  \n  if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }\n  return uVar1;\n}" ({ "{") (declaration "undefined4 uVar1;" (type_identifier "undefined4") (identifier "uVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int *piVar3;" (primitive_type "int") (pointer_declarator "*piVar3" (* "*") (identifier "piVar3")) (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (if_statement "if ((param_2 & 0x18) == 0) {\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }\n  else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" (if "if") (parenthesized_expression "((param_2 & 0x18) == 0)" (( "(") (binary_expression "(param_2 & 0x18) == 0" (parenthesized_expression "(param_2 & 0x18)" (( "(") (binary_expression "param_2 & 0x18" (identifier "param_2") (& "&") (number_literal "0x18")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n    uVar1 = 0xffffffff;\n  }" ({ "{") (expression_statement "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);" (call_expression "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_0013124c)" (( "(") (pointer_expression "*(code *)PTR_FUN_0013124c" (* "*") (cast_expression "(code *)PTR_FUN_0013124c" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_FUN_0013124c"))) () ")")) (argument_list "(PTR_FUN_001311a4 + -0x6fc0,param_1)" (( "(") (binary_expression "PTR_FUN_001311a4 + -0x6fc0" (identifier "PTR_FUN_001311a4") (+ "+") (number_literal "-0x6fc0")) (, ",") (identifier "param_1") () ")"))) (; ";")) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" (identifier "uVar1") (= "=") (number_literal "0xffffffff")) (; ";")) (} "}")) (else_clause "else {\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" (else "else") (compound_statement "{\n    piVar3 = *(int **)PTR_DAT_001311d8;\n    iVar4 = *piVar3;\n    if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }\n    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);\n    if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }\n  }" ({ "{") (expression_statement "piVar3 = *(int **)PTR_DAT_001311d8;" (assignment_expression "piVar3 = *(int **)PTR_DAT_001311d8" (identifier "piVar3") (= "=") (pointer_expression "*(int **)PTR_DAT_001311d8" (* "*") (cast_expression "(int **)PTR_DAT_001311d8" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (identifier "PTR_DAT_001311d8")))) (; ";")) (expression_statement "iVar4 = *piVar3;" (assignment_expression "iVar4 = *piVar3" (identifier "iVar4") (= "=") (pointer_expression "*piVar3" (* "*") (identifier "piVar3"))) (; ";")) (if_statement "if ((param_2 & 0x10) != 0) {\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" (if "if") (parenthesized_expression "((param_2 & 0x10) != 0)" (( "(") (binary_expression "(param_2 & 0x10) != 0" (parenthesized_expression "(param_2 & 0x10)" (( "(") (binary_expression "param_2 & 0x10" (identifier "param_2") (& "&") (number_literal "0x10")) () ")")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      (*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);\n      iVar2 = FUN_000ecf64();\n      if (iVar2 == 0) {\n        return 0;\n      }\n    }" ({ "{") (expression_statement "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1);" (call_expression "(*(code *)PTR___fprintf_chk_00131d28)\n                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1)" (parenthesized_expression "(*(code *)PTR___fprintf_chk_00131d28)" (( "(") (pointer_expression "*(code *)PTR___fprintf_chk_00131d28" (* "*") (cast_expression "(code *)PTR___fprintf_chk_00131d28" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___fprintf_chk_00131d28"))) () ")")) (argument_list "(*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,\n                 *(undefined4 *)PTR_DAT_001311ac,param_1)" (( "(") (pointer_expression "*(undefined4 *)PTR_stderr_0013219c" (* "*") (cast_expression "(undefined4 *)PTR_stderr_0013219c" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_stderr_0013219c"))) (, ",") (number_literal "1") (, ",") (binary_expression "PTR_FUN_001311a4 + 0x5814" (identifier "PTR_FUN_001311a4") (+ "+") (number_literal "0x5814")) (, ",") (pointer_expression "*(undefined4 *)PTR_DAT_001311ac" (* "*") (cast_expression "(undefined4 *)PTR_DAT_001311ac" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_DAT_001311ac"))) (, ",") (identifier "param_1") () ")"))) (; ";")) (expression_statement "iVar2 = FUN_000ecf64();" (assignment_expression "iVar2 = FUN_000ecf64()" (identifier "iVar2") (= "=") (call_expression "FUN_000ecf64()" (identifier "FUN_000ecf64") (argument_list "()" (( "(") () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n        return 0;\n      }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        return 0;\n      }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (} "}"))) (expression_statement "iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);" (assignment_expression "iVar2 = (*(code *)PTR_unlink_001320a8)(param_1)" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_unlink_001320a8)(param_1)" (parenthesized_expression "(*(code *)PTR_unlink_001320a8)" (( "(") (pointer_expression "*(code *)PTR_unlink_001320a8" (* "*") (cast_expression "(code *)PTR_unlink_001320a8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_unlink_001320a8"))) () ")")) (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (; ";")) (if_statement "if (iVar2 < 0) {\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }\n    else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" (if "if") (parenthesized_expression "(iVar2 < 0)" (( "(") (binary_expression "iVar2 < 0" (identifier "iVar2") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n      if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }\n    }" ({ "{") (if_statement "if ((*piVar3 == iVar4) && (iVar4 == 2)) {\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }\n      else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" (if "if") (parenthesized_expression "((*piVar3 == iVar4) && (iVar4 == 2))" (( "(") (binary_expression "(*piVar3 == iVar4) && (iVar4 == 2)" (parenthesized_expression "(*piVar3 == iVar4)" (( "(") (binary_expression "*piVar3 == iVar4" (pointer_expression "*piVar3" (* "*") (identifier "piVar3")) (== "==") (identifier "iVar4")) () ")")) (&& "&&") (parenthesized_expression "(iVar4 == 2)" (( "(") (binary_expression "iVar4 == 2" (identifier "iVar4") (== "==") (number_literal "2")) () ")"))) () ")")) (compound_statement "{\n        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);\n        uVar1 = 0xffffffff;\n      }" ({ "{") (expression_statement "(*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);" (call_expression "(*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_001311d0)" (( "(") (pointer_expression "*(code *)PTR_FUN_001311d0" (* "*") (cast_expression "(code *)PTR_FUN_001311d0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_FUN_001311d0"))) () ")")) (argument_list "(PTR_FUN_001311a4 + 0x582c,param_1)" (( "(") (binary_expression "PTR_FUN_001311a4 + 0x582c" (identifier "PTR_FUN_001311a4") (+ "+") (number_literal "0x582c")) (, ",") (identifier "param_1") () ")"))) (; ";")) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" (identifier "uVar1") (= "=") (number_literal "0xffffffff")) (; ";")) (} "}")) (else_clause "else {\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" (else "else") (compound_statement "{\n        *piVar3 = iVar4;\n        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);\n        uVar1 = 0xffffffff;\n      }" ({ "{") (expression_statement "*piVar3 = iVar4;" (assignment_expression "*piVar3 = iVar4" (pointer_expression "*piVar3" (* "*") (identifier "piVar3")) (= "=") (identifier "iVar4")) (; ";")) (expression_statement "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);" (call_expression "(*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1)" (parenthesized_expression "(*(code *)PTR_FUN_0013124c)" (( "(") (pointer_expression "*(code *)PTR_FUN_0013124c" (* "*") (cast_expression "(code *)PTR_FUN_0013124c" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_FUN_0013124c"))) () ")")) (argument_list "(PTR_FUN_001311a4 + -0x6fc0,param_1)" (( "(") (binary_expression "PTR_FUN_001311a4 + -0x6fc0" (identifier "PTR_FUN_001311a4") (+ "+") (number_literal "-0x6fc0")) (, ",") (identifier "param_1") () ")"))) (; ";")) (expression_statement "uVar1 = 0xffffffff;" (assignment_expression "uVar1 = 0xffffffff" (identifier "uVar1") (= "=") (number_literal "0xffffffff")) (; ";")) (} "}")))) (} "}")) (else_clause "else {\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" (else "else") (compound_statement "{\n      uVar1 = 1;\n      if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }\n    }" ({ "{") (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" (identifier "uVar1") (= "=") (number_literal "1")) (; ";")) (if_statement "if ((param_2 & 0x9000) == 0x9000) {\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }" (if "if") (parenthesized_expression "((param_2 & 0x9000) == 0x9000)" (( "(") (binary_expression "(param_2 & 0x9000) == 0x9000" (parenthesized_expression "(param_2 & 0x9000)" (( "(") (binary_expression "param_2 & 0x9000" (identifier "param_2") (& "&") (number_literal "0x9000")) () ")")) (== "==") (number_literal "0x9000")) () ")")) (compound_statement "{\n        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);\n        uVar1 = 1;\n      }" ({ "{") (expression_statement "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);" (call_expression "(*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1)" (parenthesized_expression "(*(code *)PTR___printf_chk_00131e4c)" (( "(") (pointer_expression "*(code *)PTR___printf_chk_00131e4c" (* "*") (cast_expression "(code *)PTR___printf_chk_00131e4c" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___printf_chk_00131e4c"))) () ")")) (argument_list "(1,PTR_FUN_001311a4 + 0x5854,param_1)" (( "(") (number_literal "1") (, ",") (binary_expression "PTR_FUN_001311a4 + 0x5854" (identifier "PTR_FUN_001311a4") (+ "+") (number_literal "0x5854")) (, ",") (identifier "param_1") () ")"))) (; ";")) (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" (identifier "uVar1") (= "=") (number_literal "1")) (; ";")) (} "}"))) (} "}")))) (} "}")))) (return_statement "return uVar1;" (return "return") (identifier "uVar1") (; ";")) (} "}")))
(translation_unit (function_definition type: (type_identifier) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (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 (binary_expression left: (identifier) right: (number_literal)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (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 (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier))) (number_literal) (binary_expression left: (identifier) right: (number_literal)) (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier))) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (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))))) (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: (identifier)) right: (identifier))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (compound_statement (expression_statement (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 (binary_expression left: (identifier) right: (number_literal)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (identifier))) (expression_statement (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 (binary_expression left: (identifier) right: (number_literal)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (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 (number_literal) (binary_expression left: (identifier) right: (number_literal)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))))))))))) (return_statement (identifier)))))

undefined4 MASKED(undefined4 param_1,uint param_2)

{
  undefined4 uVar1;
  int iVar2;
  int *piVar3;
  int iVar4;
  
  if ((param_2 & 0x18) == 0) {
    (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);
    uVar1 = 0xffffffff;
  }
  else {
    piVar3 = *(int **)PTR_DAT_001311d8;
    iVar4 = *piVar3;
    if ((param_2 & 0x10) != 0) {
      (*(code *)PTR___fprintf_chk_00131d28)
                (*(undefined4 *)PTR_stderr_0013219c,1,PTR_FUN_001311a4 + 0x5814,
                 *(undefined4 *)PTR_DAT_001311ac,param_1);
      iVar2 = FUN_000ecf64();
      if (iVar2 == 0) {
        return 0;
      }
    }
    iVar2 = (*(code *)PTR_unlink_001320a8)(param_1);
    if (iVar2 < 0) {
      if ((*piVar3 == iVar4) && (iVar4 == 2)) {
        (*(code *)PTR_FUN_001311d0)(PTR_FUN_001311a4 + 0x582c,param_1);
        uVar1 = 0xffffffff;
      }
      else {
        *piVar3 = iVar4;
        (*(code *)PTR_FUN_0013124c)(PTR_FUN_001311a4 + -0x6fc0,param_1);
        uVar1 = 0xffffffff;
      }
    }
    else {
      uVar1 = 1;
      if ((param_2 & 0x9000) == 0x9000) {
        (*(code *)PTR___printf_chk_00131e4c)(1,PTR_FUN_001311a4 + 0x5854,param_1);
        uVar1 = 1;
      }
    }
  }
  return uVar1;
}

