
void * open_settings_w(char *sessionname,char **errmsg)

{
  char *pcVar1;
  char *pcVar2;
  void *pvVar3;
  char *pcVar4;
  undefined4 *puVar5;
  undefined4 uVar6;
  
  *errmsg = (char *)0x0;
  pcVar1 = make_filename(0,(char *)0x0);
  pcVar2 = make_dir_path(pcVar1,0x1c0);
  if (pcVar2 == (char *)0x0) {
    (*(code *)PTR_safefree_000800c4)(pcVar1);
    pcVar1 = make_filename(4,(char *)0x0);
    pcVar2 = make_dir_path(pcVar1,0x1c0);
    if (pcVar2 == (char *)0x0) {
      (*(code *)PTR_safefree_000800c4)(pcVar1);
      pcVar1 = make_filename(5,sessionname);
      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);
      if (pvVar3 == (void *)0x0) {
        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();
        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);
        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);
        *errmsg = pcVar2;
        (*(code *)PTR_safefree_000800c4)(pcVar1);
      }
      else {
        (*(code *)PTR_safefree_000800c4)(pcVar1);
      }
    }
    else {
      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);
      *errmsg = pcVar4;
      (*(code *)PTR_safefree_000800c4)(pcVar2);
      (*(code *)PTR_safefree_000800c4)(pcVar1);
      pvVar3 = (void *)0x0;
    }
  }
  else {
    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);
    *errmsg = pcVar4;
    (*(code *)PTR_safefree_000800c4)(pcVar2);
    (*(code *)PTR_safefree_000800c4)(pcVar1);
    pvVar3 = (void *)0x0;
  }
  return pvVar3;
}



int open_settings_w(undefined4 param_1,undefined4 *param_2)

{
  undefined4 uVar1;
  int iVar2;
  undefined4 *puVar3;
  undefined4 uVar4;
  
  *param_2 = 0;
  uVar1 = FUN_0005ef50(0,0);
  iVar2 = make_dir_path(uVar1,0x1c0);
  if (iVar2 == 0) {
    (*(code *)PTR_safefree_000800c4)(uVar1);
    uVar1 = FUN_0005ef50(4,0);
    iVar2 = make_dir_path(uVar1,0x1c0);
    if (iVar2 == 0) {
      (*(code *)PTR_safefree_000800c4)(uVar1);
      uVar1 = FUN_0005ef50(5,param_1);
      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);
      if (iVar2 == 0) {
        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();
        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);
        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);
        *param_2 = uVar4;
        (*(code *)PTR_safefree_000800c4)(uVar1);
      }
      else {
        (*(code *)PTR_safefree_000800c4)(uVar1);
      }
    }
    else {
      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);
      *param_2 = uVar4;
      (*(code *)PTR_safefree_000800c4)(iVar2);
      (*(code *)PTR_safefree_000800c4)(uVar1);
      iVar2 = 0;
    }
  }
  else {
    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);
    *param_2 = uVar4;
    (*(code *)PTR_safefree_000800c4)(iVar2);
    (*(code *)PTR_safefree_000800c4)(uVar1);
    iVar2 = 0;
  }
  return iVar2;
}


lui gp,0x3
addiu gp,gp,-0x7794
addu gp,gp,t9
addiu sp,sp,-0x30
sw ra,0x2c(sp)
sw s4,0x28(sp)
sw s3,0x24(sp)
sw s2,0x20(sp)
sw s1,0x1c(sp)
sw s0,0x18(sp)
sw gp,0x10(sp)
or s3,a0,zero
or s2,a1,zero
sw zero,0x0(a1)
or a1,zero,zero
or a0,zero,zero
lw t9,-0x7fc8(gp)
addiu t9,t9,-0x10b0
bal 0x0005ef50
_nop
lw gp,0x10(sp)
or s1,v0,zero
li a1,0x1c0
or a0,v0,zero
lw t9,-0x7a14(gp)
bal 0x00057070
_nop
lw gp,0x10(sp)
bne v0,zero,0x0005f960
_or s0,v0,zero
or a0,s1,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
or a1,zero,zero
li a0,0x4
lw t9,-0x7fc8(gp)
addiu t9,t9,-0x10b0
bal 0x0005ef50
_nop
lw gp,0x10(sp)
or s1,v0,zero
li a1,0x1c0
or a0,v0,zero
lw t9,-0x7a14(gp)
bal 0x00057070
_nop
lw gp,0x10(sp)
bne v0,zero,0x0005f9b0
_or s4,v0,zero
or a0,s1,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
or a1,s3,zero
li a0,0x5
lw t9,-0x7fc8(gp)
addiu t9,t9,-0x10b0
bal 0x0005ef50
_nop
lw gp,0x10(sp)
or s1,v0,zero
lw a1,-0x7f3c(gp)
addiu a1,a1,-0x49b0
or a0,v0,zero
lw t9,-0x7720(gp)
jalr t9
_nop
lw gp,0x10(sp)
beq v0,zero,0x0005fa00
_or s0,v0,zero
or a0,s1,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
or v0,s0,zero
lw ra,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,0x30
or a1,v0,zero
lw a0,-0x7f3c(gp)
addiu a0,a0,-0x1d68
lw t9,-0x7fb8(gp)
jalr t9
_nop
lw gp,0x10(sp)
sw v0,0x0(s2)
or a0,s0,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
or a0,s1,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
b 0x0005f93c
_or s0,zero,zero
or a1,v0,zero
lw a0,-0x7f3c(gp)
addiu a0,a0,-0x1d68
lw t9,-0x7fb8(gp)
jalr t9
_nop
lw gp,0x10(sp)
sw v0,0x0(s2)
or a0,s4,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
or a0,s1,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
b 0x0005f940
_or v0,s0,zero
lw t9,-0x77b8(gp)
jalr t9
_nop
lw gp,0x10(sp)
lw a0,0x0(v0)
lw t9,-0x78c0(gp)
jalr t9
_nop
lw gp,0x10(sp)
or a2,v0,zero
or a1,s1,zero
lw a0,-0x7f3c(gp)
addiu a0,a0,-0x1d4c
lw t9,-0x7fb8(gp)
jalr t9
_nop
lw gp,0x10(sp)
sw v0,0x0(s2)
or a0,s1,zero
lw t9,-0x7fac(gp)
jalr t9
_nop
lw gp,0x10(sp)
b 0x0005f940
_or v0,s0,zero
(translation_unit "int open_settings_w(undefined4 param_1,undefined4 *param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}\n\n" (function_definition "int open_settings_w(undefined4 param_1,undefined4 *param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}" primitive_type (function_declarator "open_settings_w(undefined4 param_1,undefined4 *param_2)" identifier (parameter_list "(undefined4 param_1,undefined4 *param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "undefined4 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "undefined4 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (expression_statement "*param_2 = 0;" (assignment_expression "*param_2 = 0" (pointer_expression "*param_2" * identifier) = number_literal) ;) (expression_statement "uVar1 = FUN_0005ef50(0,0);" (assignment_expression "uVar1 = FUN_0005ef50(0,0)" identifier = (call_expression "FUN_0005ef50(0,0)" identifier (argument_list "(0,0)" ( number_literal , number_literal )))) ;) (expression_statement "iVar2 = make_dir_path(uVar1,0x1c0);" (assignment_expression "iVar2 = make_dir_path(uVar1,0x1c0)" identifier = (call_expression "make_dir_path(uVar1,0x1c0)" identifier (argument_list "(uVar1,0x1c0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "uVar1 = FUN_0005ef50(4,0);" (assignment_expression "uVar1 = FUN_0005ef50(4,0)" identifier = (call_expression "FUN_0005ef50(4,0)" identifier (argument_list "(4,0)" ( number_literal , number_literal )))) ;) (expression_statement "iVar2 = make_dir_path(uVar1,0x1c0);" (assignment_expression "iVar2 = make_dir_path(uVar1,0x1c0)" identifier = (call_expression "make_dir_path(uVar1,0x1c0)" identifier (argument_list "(uVar1,0x1c0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "uVar1 = FUN_0005ef50(5,param_1);" (assignment_expression "uVar1 = FUN_0005ef50(5,param_1)" identifier = (call_expression "FUN_0005ef50(5,param_1)" identifier (argument_list "(5,param_1)" ( number_literal , identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);" (assignment_expression "iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0)" identifier = (call_expression "(*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0)" (parenthesized_expression "(*(code *)PTR_fopen64_00080950)" ( (pointer_expression "*(code *)PTR_fopen64_00080950" * (cast_expression "(code *)PTR_fopen64_00080950" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1,PTR_DAT_00080134 + -0x49b0)" ( identifier , (binary_expression "PTR_DAT_00080134 + -0x49b0" identifier + number_literal) )))) ;) (if_statement "if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" { (expression_statement "puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();" (assignment_expression "puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)()" identifier = (cast_expression "(undefined4 *)(*(code *)PTR___errno_location_000808b8)()" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR___errno_location_000808b8)()" (parenthesized_expression "(*(code *)PTR___errno_location_000808b8)" ( (pointer_expression "*(code *)PTR___errno_location_000808b8" * (cast_expression "(code *)PTR___errno_location_000808b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))))) ;) (expression_statement "uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);" (assignment_expression "uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3)" identifier = (call_expression "(*(code *)PTR_strerror_000807b0)(*puVar3)" (parenthesized_expression "(*(code *)PTR_strerror_000807b0)" ( (pointer_expression "*(code *)PTR_strerror_000807b0" * (cast_expression "(code *)PTR_strerror_000807b0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*puVar3)" ( (pointer_expression "*puVar3" * identifier) )))) ;) (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" identifier = (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" ( (binary_expression "PTR_DAT_00080134 + -0x1d4c" identifier + number_literal) , identifier , identifier )))) ;) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) }) (else_clause "else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" else (compound_statement "{\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) }))) }) (else_clause "else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" else (compound_statement "{\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" { (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" identifier = (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d68,iVar2)" ( (binary_expression "PTR_DAT_00080134 + -0x1d68" identifier + number_literal) , identifier )))) ;) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(iVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(iVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }))) }) (else_clause "else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" else (compound_statement "{\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" { (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" identifier = (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d68,iVar2)" ( (binary_expression "PTR_DAT_00080134 + -0x1d68" identifier + number_literal) , identifier )))) ;) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(iVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(iVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }))) (return_statement "return iVar2;" return identifier ;) })))
(translation_unit "void * open_settings_w(char *sessionname,char **errmsg)\n\n{\n  char *pcVar1;\n  char *pcVar2;\n  void *pvVar3;\n  char *pcVar4;\n  undefined4 *puVar5;\n  undefined4 uVar6;\n  \n  *errmsg = (char *)0x0;\n  pcVar1 = make_filename(0,(char *)0x0);\n  pcVar2 = make_dir_path(pcVar1,0x1c0);\n  if (pcVar2 == (char *)0x0) {\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pcVar1 = make_filename(4,(char *)0x0);\n    pcVar2 = make_dir_path(pcVar1,0x1c0);\n    if (pcVar2 == (char *)0x0) {\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }\n    else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }\n  }\n  else {\n    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n    *errmsg = pcVar4;\n    (*(code *)PTR_safefree_000800c4)(pcVar2);\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pvVar3 = (void *)0x0;\n  }\n  return pvVar3;\n}\n\n" (function_definition "void * open_settings_w(char *sessionname,char **errmsg)\n\n{\n  char *pcVar1;\n  char *pcVar2;\n  void *pvVar3;\n  char *pcVar4;\n  undefined4 *puVar5;\n  undefined4 uVar6;\n  \n  *errmsg = (char *)0x0;\n  pcVar1 = make_filename(0,(char *)0x0);\n  pcVar2 = make_dir_path(pcVar1,0x1c0);\n  if (pcVar2 == (char *)0x0) {\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pcVar1 = make_filename(4,(char *)0x0);\n    pcVar2 = make_dir_path(pcVar1,0x1c0);\n    if (pcVar2 == (char *)0x0) {\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }\n    else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }\n  }\n  else {\n    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n    *errmsg = pcVar4;\n    (*(code *)PTR_safefree_000800c4)(pcVar2);\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pvVar3 = (void *)0x0;\n  }\n  return pvVar3;\n}" primitive_type (pointer_declarator "* open_settings_w(char *sessionname,char **errmsg)" * (function_declarator "open_settings_w(char *sessionname,char **errmsg)" identifier (parameter_list "(char *sessionname,char **errmsg)" ( (parameter_declaration "char *sessionname" primitive_type (pointer_declarator "*sessionname" * identifier)) , (parameter_declaration "char **errmsg" primitive_type (pointer_declarator "**errmsg" * (pointer_declarator "*errmsg" * identifier))) )))) (compound_statement "{\n  char *pcVar1;\n  char *pcVar2;\n  void *pvVar3;\n  char *pcVar4;\n  undefined4 *puVar5;\n  undefined4 uVar6;\n  \n  *errmsg = (char *)0x0;\n  pcVar1 = make_filename(0,(char *)0x0);\n  pcVar2 = make_dir_path(pcVar1,0x1c0);\n  if (pcVar2 == (char *)0x0) {\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pcVar1 = make_filename(4,(char *)0x0);\n    pcVar2 = make_dir_path(pcVar1,0x1c0);\n    if (pcVar2 == (char *)0x0) {\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }\n    else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }\n  }\n  else {\n    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n    *errmsg = pcVar4;\n    (*(code *)PTR_safefree_000800c4)(pcVar2);\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pvVar3 = (void *)0x0;\n  }\n  return pvVar3;\n}" { (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (declaration "void *pvVar3;" primitive_type (pointer_declarator "*pvVar3" * identifier) ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (declaration "undefined4 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (declaration "undefined4 uVar6;" type_identifier identifier ;) (expression_statement "*errmsg = (char *)0x0;" (assignment_expression "*errmsg = (char *)0x0" (pointer_expression "*errmsg" * identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "pcVar1 = make_filename(0,(char *)0x0);" (assignment_expression "pcVar1 = make_filename(0,(char *)0x0)" identifier = (call_expression "make_filename(0,(char *)0x0)" identifier (argument_list "(0,(char *)0x0)" ( number_literal , (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) )))) ;) (expression_statement "pcVar2 = make_dir_path(pcVar1,0x1c0);" (assignment_expression "pcVar2 = make_dir_path(pcVar1,0x1c0)" identifier = (call_expression "make_dir_path(pcVar1,0x1c0)" identifier (argument_list "(pcVar1,0x1c0)" ( identifier , number_literal )))) ;) (if_statement "if (pcVar2 == (char *)0x0) {\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pcVar1 = make_filename(4,(char *)0x0);\n    pcVar2 = make_dir_path(pcVar1,0x1c0);\n    if (pcVar2 == (char *)0x0) {\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }\n    else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }\n  }\n  else {\n    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n    *errmsg = pcVar4;\n    (*(code *)PTR_safefree_000800c4)(pcVar2);\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pvVar3 = (void *)0x0;\n  }" if (parenthesized_expression "(pcVar2 == (char *)0x0)" ( (binary_expression "pcVar2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pcVar1 = make_filename(4,(char *)0x0);\n    pcVar2 = make_dir_path(pcVar1,0x1c0);\n    if (pcVar2 == (char *)0x0) {\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }\n    else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }\n  }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "pcVar1 = make_filename(4,(char *)0x0);" (assignment_expression "pcVar1 = make_filename(4,(char *)0x0)" identifier = (call_expression "make_filename(4,(char *)0x0)" identifier (argument_list "(4,(char *)0x0)" ( number_literal , (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) )))) ;) (expression_statement "pcVar2 = make_dir_path(pcVar1,0x1c0);" (assignment_expression "pcVar2 = make_dir_path(pcVar1,0x1c0)" identifier = (call_expression "make_dir_path(pcVar1,0x1c0)" identifier (argument_list "(pcVar1,0x1c0)" ( identifier , number_literal )))) ;) (if_statement "if (pcVar2 == (char *)0x0) {\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }\n    else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }" if (parenthesized_expression "(pcVar2 == (char *)0x0)" ( (binary_expression "pcVar2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pcVar1 = make_filename(5,sessionname);\n      pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);\n      if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n    }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "pcVar1 = make_filename(5,sessionname);" (assignment_expression "pcVar1 = make_filename(5,sessionname)" identifier = (call_expression "make_filename(5,sessionname)" identifier (argument_list "(5,sessionname)" ( number_literal , identifier )))) ;) (expression_statement "pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0);" (assignment_expression "pvVar3 = (void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0)" identifier = (cast_expression "(void *)(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_fopen64_00080950)(pcVar1,PTR_DAT_00080134 + -0x49b0)" (parenthesized_expression "(*(code *)PTR_fopen64_00080950)" ( (pointer_expression "*(code *)PTR_fopen64_00080950" * (cast_expression "(code *)PTR_fopen64_00080950" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1,PTR_DAT_00080134 + -0x49b0)" ( identifier , (binary_expression "PTR_DAT_00080134 + -0x49b0" identifier + number_literal) ))))) ;) (if_statement "if (pvVar3 == (void *)0x0) {\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }" if (parenthesized_expression "(pvVar3 == (void *)0x0)" ( (binary_expression "pvVar3 == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);\n        pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);\n        *errmsg = pcVar2;\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }" { (expression_statement "puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();" (assignment_expression "puVar5 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)()" identifier = (cast_expression "(undefined4 *)(*(code *)PTR___errno_location_000808b8)()" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR___errno_location_000808b8)()" (parenthesized_expression "(*(code *)PTR___errno_location_000808b8)" ( (pointer_expression "*(code *)PTR___errno_location_000808b8" * (cast_expression "(code *)PTR___errno_location_000808b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))))) ;) (expression_statement "uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5);" (assignment_expression "uVar6 = (*(code *)PTR_strerror_000807b0)(*puVar5)" identifier = (call_expression "(*(code *)PTR_strerror_000807b0)(*puVar5)" (parenthesized_expression "(*(code *)PTR_strerror_000807b0)" ( (pointer_expression "*(code *)PTR_strerror_000807b0" * (cast_expression "(code *)PTR_strerror_000807b0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*puVar5)" ( (pointer_expression "*puVar5" * identifier) )))) ;) (expression_statement "pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6);" (assignment_expression "pcVar2 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6)" identifier = (cast_expression "(char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d4c,pcVar1,uVar6)" ( (binary_expression "PTR_DAT_00080134 + -0x1d4c" identifier + number_literal) , identifier , identifier ))))) ;) (expression_statement "*errmsg = pcVar2;" (assignment_expression "*errmsg = pcVar2" (pointer_expression "*errmsg" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) }) (else_clause "else {\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }" else (compound_statement "{\n        (*(code *)PTR_safefree_000800c4)(pcVar1);\n      }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) }))) }) (else_clause "else {\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }" else (compound_statement "{\n      pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n      *errmsg = pcVar4;\n      (*(code *)PTR_safefree_000800c4)(pcVar2);\n      (*(code *)PTR_safefree_000800c4)(pcVar1);\n      pvVar3 = (void *)0x0;\n    }" { (expression_statement "pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);" (assignment_expression "pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2)" identifier = (cast_expression "(char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d68,pcVar2)" ( (binary_expression "PTR_DAT_00080134 + -0x1d68" identifier + number_literal) , identifier ))))) ;) (expression_statement "*errmsg = pcVar4;" (assignment_expression "*errmsg = pcVar4" (pointer_expression "*errmsg" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar2)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "pvVar3 = (void *)0x0;" (assignment_expression "pvVar3 = (void *)0x0" identifier = (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) }))) }) (else_clause "else {\n    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n    *errmsg = pcVar4;\n    (*(code *)PTR_safefree_000800c4)(pcVar2);\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pvVar3 = (void *)0x0;\n  }" else (compound_statement "{\n    pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);\n    *errmsg = pcVar4;\n    (*(code *)PTR_safefree_000800c4)(pcVar2);\n    (*(code *)PTR_safefree_000800c4)(pcVar1);\n    pvVar3 = (void *)0x0;\n  }" { (expression_statement "pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2);" (assignment_expression "pcVar4 = (char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2)" identifier = (cast_expression "(char *)(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,pcVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d68,pcVar2)" ( (binary_expression "PTR_DAT_00080134 + -0x1d68" identifier + number_literal) , identifier ))))) ;) (expression_statement "*errmsg = pcVar4;" (assignment_expression "*errmsg = pcVar4" (pointer_expression "*errmsg" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar2)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(pcVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(pcVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "pvVar3 = (void *)0x0;" (assignment_expression "pvVar3 = (void *)0x0" identifier = (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) }))) (return_statement "return pvVar3;" return identifier ;) })))
(translation_unit "int open_settings_w(undefined4 param_1,undefined4 *param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}\n\n" (function_definition "int open_settings_w(undefined4 param_1,undefined4 *param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}" primitive_type (function_declarator "open_settings_w(undefined4 param_1,undefined4 *param_2)" identifier (parameter_list "(undefined4 param_1,undefined4 *param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "undefined4 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}" { (declaration "undefined4 uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "undefined4 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (expression_statement "*param_2 = 0;" (assignment_expression "*param_2 = 0" (pointer_expression "*param_2" * identifier) = number_literal) ;) (expression_statement "uVar1 = FUN_0005ef50(0,0);" (assignment_expression "uVar1 = FUN_0005ef50(0,0)" identifier = (call_expression "FUN_0005ef50(0,0)" identifier (argument_list "(0,0)" ( number_literal , number_literal )))) ;) (expression_statement "iVar2 = make_dir_path(uVar1,0x1c0);" (assignment_expression "iVar2 = make_dir_path(uVar1,0x1c0)" identifier = (call_expression "make_dir_path(uVar1,0x1c0)" identifier (argument_list "(uVar1,0x1c0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "uVar1 = FUN_0005ef50(4,0);" (assignment_expression "uVar1 = FUN_0005ef50(4,0)" identifier = (call_expression "FUN_0005ef50(4,0)" identifier (argument_list "(4,0)" ( number_literal , number_literal )))) ;) (expression_statement "iVar2 = make_dir_path(uVar1,0x1c0);" (assignment_expression "iVar2 = make_dir_path(uVar1,0x1c0)" identifier = (call_expression "make_dir_path(uVar1,0x1c0)" identifier (argument_list "(uVar1,0x1c0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "uVar1 = FUN_0005ef50(5,param_1);" (assignment_expression "uVar1 = FUN_0005ef50(5,param_1)" identifier = (call_expression "FUN_0005ef50(5,param_1)" identifier (argument_list "(5,param_1)" ( number_literal , identifier )))) ;) (expression_statement "iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);" (assignment_expression "iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0)" identifier = (call_expression "(*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0)" (parenthesized_expression "(*(code *)PTR_fopen64_00080950)" ( (pointer_expression "*(code *)PTR_fopen64_00080950" * (cast_expression "(code *)PTR_fopen64_00080950" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1,PTR_DAT_00080134 + -0x49b0)" ( identifier , (binary_expression "PTR_DAT_00080134 + -0x49b0" identifier + number_literal) )))) ;) (if_statement "if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" { (expression_statement "puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();" (assignment_expression "puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)()" identifier = (cast_expression "(undefined4 *)(*(code *)PTR___errno_location_000808b8)()" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR___errno_location_000808b8)()" (parenthesized_expression "(*(code *)PTR___errno_location_000808b8)" ( (pointer_expression "*(code *)PTR___errno_location_000808b8" * (cast_expression "(code *)PTR___errno_location_000808b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))))) ;) (expression_statement "uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);" (assignment_expression "uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3)" identifier = (call_expression "(*(code *)PTR_strerror_000807b0)(*puVar3)" (parenthesized_expression "(*(code *)PTR_strerror_000807b0)" ( (pointer_expression "*(code *)PTR_strerror_000807b0" * (cast_expression "(code *)PTR_strerror_000807b0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*puVar3)" ( (pointer_expression "*puVar3" * identifier) )))) ;) (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" identifier = (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" ( (binary_expression "PTR_DAT_00080134 + -0x1d4c" identifier + number_literal) , identifier , identifier )))) ;) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) }) (else_clause "else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" else (compound_statement "{\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" { (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) }))) }) (else_clause "else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" else (compound_statement "{\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" { (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" identifier = (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d68,iVar2)" ( (binary_expression "PTR_DAT_00080134 + -0x1d68" identifier + number_literal) , identifier )))) ;) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(iVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(iVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }))) }) (else_clause "else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" else (compound_statement "{\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" { (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" identifier = (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" ( (pointer_expression "*(code *)PTR_dupprintf_000800b8" * (cast_expression "(code *)PTR_dupprintf_000800b8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(PTR_DAT_00080134 + -0x1d68,iVar2)" ( (binary_expression "PTR_DAT_00080134 + -0x1d68" identifier + number_literal) , identifier )))) ;) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" * identifier) = identifier) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(iVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(iVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" ( (pointer_expression "*(code *)PTR_safefree_000800c4" * (cast_expression "(code *)PTR_safefree_000800c4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(uVar1)" ( identifier ))) ;) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }))) (return_statement "return iVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , LIT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT )))) ;) (if_statement if (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 ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , LIT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT )))) ;) (if_statement if (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 ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , (binary_expression IDENT + LIT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( ))))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * IDENT) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) , IDENT , IDENT )))) ;) (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 ( IDENT ))) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) }))) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) , IDENT )))) ;) (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 ( IDENT ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }))) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) , IDENT )))) ;) (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 ( IDENT ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }))) (return_statement return IDENT ;) })))
(function_definition "int open_settings_w(undefined4 param_1,undefined4 *param_2)\n\n{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}" (primitive_type "int") (function_declarator "open_settings_w(undefined4 param_1,undefined4 *param_2)" (identifier "open_settings_w") (parameter_list "(undefined4 param_1,undefined4 *param_2)" (( "(") (parameter_declaration "undefined4 param_1" (type_identifier "undefined4") (identifier "param_1")) (, ",") (parameter_declaration "undefined4 *param_2" (type_identifier "undefined4") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")"))) (compound_statement "{\n  undefined4 uVar1;\n  int iVar2;\n  undefined4 *puVar3;\n  undefined4 uVar4;\n  \n  *param_2 = 0;\n  uVar1 = FUN_0005ef50(0,0);\n  iVar2 = make_dir_path(uVar1,0x1c0);\n  if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }\n  return iVar2;\n}" ({ "{") (declaration "undefined4 uVar1;" (type_identifier "undefined4") (identifier "uVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "undefined4 *puVar3;" (type_identifier "undefined4") (pointer_declarator "*puVar3" (* "*") (identifier "puVar3")) (; ";")) (declaration "undefined4 uVar4;" (type_identifier "undefined4") (identifier "uVar4") (; ";")) (expression_statement "*param_2 = 0;" (assignment_expression "*param_2 = 0" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (number_literal "0")) (; ";")) (expression_statement "uVar1 = FUN_0005ef50(0,0);" (assignment_expression "uVar1 = FUN_0005ef50(0,0)" (identifier "uVar1") (= "=") (call_expression "FUN_0005ef50(0,0)" (identifier "FUN_0005ef50") (argument_list "(0,0)" (( "(") (number_literal "0") (, ",") (number_literal "0") () ")")))) (; ";")) (expression_statement "iVar2 = make_dir_path(uVar1,0x1c0);" (assignment_expression "iVar2 = make_dir_path(uVar1,0x1c0)" (identifier "iVar2") (= "=") (call_expression "make_dir_path(uVar1,0x1c0)" (identifier "make_dir_path") (argument_list "(uVar1,0x1c0)" (( "(") (identifier "uVar1") (, ",") (number_literal "0x1c0") () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }\n  else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    uVar1 = FUN_0005ef50(4,0);\n    iVar2 = make_dir_path(uVar1,0x1c0);\n    if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }\n  }" ({ "{") (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")"))) (; ";")) (expression_statement "uVar1 = FUN_0005ef50(4,0);" (assignment_expression "uVar1 = FUN_0005ef50(4,0)" (identifier "uVar1") (= "=") (call_expression "FUN_0005ef50(4,0)" (identifier "FUN_0005ef50") (argument_list "(4,0)" (( "(") (number_literal "4") (, ",") (number_literal "0") () ")")))) (; ";")) (expression_statement "iVar2 = make_dir_path(uVar1,0x1c0);" (assignment_expression "iVar2 = make_dir_path(uVar1,0x1c0)" (identifier "iVar2") (= "=") (call_expression "make_dir_path(uVar1,0x1c0)" (identifier "make_dir_path") (argument_list "(uVar1,0x1c0)" (( "(") (identifier "uVar1") (, ",") (number_literal "0x1c0") () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }\n    else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      uVar1 = FUN_0005ef50(5,param_1);\n      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);\n      if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n    }" ({ "{") (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")"))) (; ";")) (expression_statement "uVar1 = FUN_0005ef50(5,param_1);" (assignment_expression "uVar1 = FUN_0005ef50(5,param_1)" (identifier "uVar1") (= "=") (call_expression "FUN_0005ef50(5,param_1)" (identifier "FUN_0005ef50") (argument_list "(5,param_1)" (( "(") (number_literal "5") (, ",") (identifier "param_1") () ")")))) (; ";")) (expression_statement "iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);" (assignment_expression "iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0)" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0)" (parenthesized_expression "(*(code *)PTR_fopen64_00080950)" (( "(") (pointer_expression "*(code *)PTR_fopen64_00080950" (* "*") (cast_expression "(code *)PTR_fopen64_00080950" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_fopen64_00080950"))) () ")")) (argument_list "(uVar1,PTR_DAT_00080134 + -0x49b0)" (( "(") (identifier "uVar1") (, ",") (binary_expression "PTR_DAT_00080134 + -0x49b0" (identifier "PTR_DAT_00080134") (+ "+") (number_literal "-0x49b0")) () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }\n      else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();\n        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);\n        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);\n        *param_2 = uVar4;\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" ({ "{") (expression_statement "puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();" (assignment_expression "puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)()" (identifier "puVar3") (= "=") (cast_expression "(undefined4 *)(*(code *)PTR___errno_location_000808b8)()" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "(*(code *)PTR___errno_location_000808b8)()" (parenthesized_expression "(*(code *)PTR___errno_location_000808b8)" (( "(") (pointer_expression "*(code *)PTR___errno_location_000808b8" (* "*") (cast_expression "(code *)PTR___errno_location_000808b8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR___errno_location_000808b8"))) () ")")) (argument_list "()" (( "(") () ")"))))) (; ";")) (expression_statement "uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);" (assignment_expression "uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3)" (identifier "uVar4") (= "=") (call_expression "(*(code *)PTR_strerror_000807b0)(*puVar3)" (parenthesized_expression "(*(code *)PTR_strerror_000807b0)" (( "(") (pointer_expression "*(code *)PTR_strerror_000807b0" (* "*") (cast_expression "(code *)PTR_strerror_000807b0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_strerror_000807b0"))) () ")")) (argument_list "(*puVar3)" (( "(") (pointer_expression "*puVar3" (* "*") (identifier "puVar3")) () ")")))) (; ";")) (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" (identifier "uVar4") (= "=") (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" (( "(") (pointer_expression "*(code *)PTR_dupprintf_000800b8" (* "*") (cast_expression "(code *)PTR_dupprintf_000800b8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_dupprintf_000800b8"))) () ")")) (argument_list "(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4)" (( "(") (binary_expression "PTR_DAT_00080134 + -0x1d4c" (identifier "PTR_DAT_00080134") (+ "+") (number_literal "-0x1d4c")) (, ",") (identifier "uVar1") (, ",") (identifier "uVar4") () ")")))) (; ";")) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (identifier "uVar4")) (; ";")) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")"))) (; ";")) (} "}")) (else_clause "else {\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" (else "else") (compound_statement "{\n        (*(code *)PTR_safefree_000800c4)(uVar1);\n      }" ({ "{") (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")"))) (; ";")) (} "}")))) (} "}")) (else_clause "else {\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" (else "else") (compound_statement "{\n      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n      *param_2 = uVar4;\n      (*(code *)PTR_safefree_000800c4)(iVar2);\n      (*(code *)PTR_safefree_000800c4)(uVar1);\n      iVar2 = 0;\n    }" ({ "{") (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (identifier "uVar4") (= "=") (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" (( "(") (pointer_expression "*(code *)PTR_dupprintf_000800b8" (* "*") (cast_expression "(code *)PTR_dupprintf_000800b8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_dupprintf_000800b8"))) () ")")) (argument_list "(PTR_DAT_00080134 + -0x1d68,iVar2)" (( "(") (binary_expression "PTR_DAT_00080134 + -0x1d68" (identifier "PTR_DAT_00080134") (+ "+") (number_literal "-0x1d68")) (, ",") (identifier "iVar2") () ")")))) (; ";")) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (identifier "uVar4")) (; ";")) (expression_statement "(*(code *)PTR_safefree_000800c4)(iVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(iVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(iVar2)" (( "(") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")"))) (; ";")) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" (identifier "iVar2") (= "=") (number_literal "0")) (; ";")) (} "}")))) (} "}")) (else_clause "else {\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" (else "else") (compound_statement "{\n    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);\n    *param_2 = uVar4;\n    (*(code *)PTR_safefree_000800c4)(iVar2);\n    (*(code *)PTR_safefree_000800c4)(uVar1);\n    iVar2 = 0;\n  }" ({ "{") (expression_statement "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);" (assignment_expression "uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (identifier "uVar4") (= "=") (call_expression "(*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2)" (parenthesized_expression "(*(code *)PTR_dupprintf_000800b8)" (( "(") (pointer_expression "*(code *)PTR_dupprintf_000800b8" (* "*") (cast_expression "(code *)PTR_dupprintf_000800b8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_dupprintf_000800b8"))) () ")")) (argument_list "(PTR_DAT_00080134 + -0x1d68,iVar2)" (( "(") (binary_expression "PTR_DAT_00080134 + -0x1d68" (identifier "PTR_DAT_00080134") (+ "+") (number_literal "-0x1d68")) (, ",") (identifier "iVar2") () ")")))) (; ";")) (expression_statement "*param_2 = uVar4;" (assignment_expression "*param_2 = uVar4" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (identifier "uVar4")) (; ";")) (expression_statement "(*(code *)PTR_safefree_000800c4)(iVar2);" (call_expression "(*(code *)PTR_safefree_000800c4)(iVar2)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(iVar2)" (( "(") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "(*(code *)PTR_safefree_000800c4)(uVar1);" (call_expression "(*(code *)PTR_safefree_000800c4)(uVar1)" (parenthesized_expression "(*(code *)PTR_safefree_000800c4)" (( "(") (pointer_expression "*(code *)PTR_safefree_000800c4" (* "*") (cast_expression "(code *)PTR_safefree_000800c4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000800c4"))) () ")")) (argument_list "(uVar1)" (( "(") (identifier "uVar1") () ")"))) (; ";")) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" (identifier "iVar2") (= "=") (number_literal "0")) (; ";")) (} "}")))) (return_statement "return iVar2;" (return "return") (identifier "iVar2") (; ";")) (} "}")))

void * function_1(char *sessionname,char **errmsg)

{
  char *pcVar1;
  char *var_3;
  void *var_5;
  char *pcVar4;
  type_1 *puVar5;
  type_1 uVar6;
  
  *errmsg = (char *)0x0;
  pcVar1 = var_1(0,(char *)0x0);
  var_3 = var_2(pcVar1,0x1c0);
  if (var_3 == (char *)0x0) {
    (*(type_2 *)PTR_safefree_000800c4)(pcVar1);
    pcVar1 = var_1(4,(char *)0x0);
    var_3 = var_2(pcVar1,0x1c0);
    if (var_3 == (char *)0x0) {
      (*(type_2 *)PTR_safefree_000800c4)(pcVar1);
      pcVar1 = var_1(5,sessionname);
      var_5 = (void *)(*(type_2 *)PTR_fopen64_00080950)(pcVar1,var_4 + -0x49b0);
      if (var_5 == (void *)0x0) {
        puVar5 = (type_1 *)(*(type_2 *)PTR___errno_location_000808b8)();
        uVar6 = (*(type_2 *)PTR_strerror_000807b0)(*puVar5);
        var_3 = (char *)(*(type_2 *)PTR_dupprintf_000800b8)(var_4 + -0x1d4c,pcVar1,uVar6);
        *errmsg = var_3;
        (*(type_2 *)PTR_safefree_000800c4)(pcVar1);
      }
      else {
        (*(type_2 *)PTR_safefree_000800c4)(pcVar1);
      }
    }
    else {
      pcVar4 = (char *)(*(type_2 *)PTR_dupprintf_000800b8)(var_4 + -0x1d68,var_3);
      *errmsg = pcVar4;
      (*(type_2 *)PTR_safefree_000800c4)(var_3);
      (*(type_2 *)PTR_safefree_000800c4)(pcVar1);
      var_5 = (void *)0x0;
    }
  }
  else {
    pcVar4 = (char *)(*(type_2 *)PTR_dupprintf_000800b8)(var_4 + -0x1d68,var_3);
    *errmsg = pcVar4;
    (*(type_2 *)PTR_safefree_000800c4)(var_3);
    (*(type_2 *)PTR_safefree_000800c4)(pcVar1);
    var_5 = (void *)0x0;
  }
  return var_5;
}


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

int MASKED(undefined4 param_1,undefined4 *param_2)

{
  undefined4 uVar1;
  int iVar2;
  undefined4 *puVar3;
  undefined4 uVar4;
  
  *param_2 = 0;
  uVar1 = FUN_0005ef50(0,0);
  iVar2 = make_dir_path(uVar1,0x1c0);
  if (iVar2 == 0) {
    (*(code *)PTR_safefree_000800c4)(uVar1);
    uVar1 = FUN_0005ef50(4,0);
    iVar2 = make_dir_path(uVar1,0x1c0);
    if (iVar2 == 0) {
      (*(code *)PTR_safefree_000800c4)(uVar1);
      uVar1 = FUN_0005ef50(5,param_1);
      iVar2 = (*(code *)PTR_fopen64_00080950)(uVar1,PTR_DAT_00080134 + -0x49b0);
      if (iVar2 == 0) {
        puVar3 = (undefined4 *)(*(code *)PTR___errno_location_000808b8)();
        uVar4 = (*(code *)PTR_strerror_000807b0)(*puVar3);
        uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d4c,uVar1,uVar4);
        *param_2 = uVar4;
        (*(code *)PTR_safefree_000800c4)(uVar1);
      }
      else {
        (*(code *)PTR_safefree_000800c4)(uVar1);
      }
    }
    else {
      uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);
      *param_2 = uVar4;
      (*(code *)PTR_safefree_000800c4)(iVar2);
      (*(code *)PTR_safefree_000800c4)(uVar1);
      iVar2 = 0;
    }
  }
  else {
    uVar4 = (*(code *)PTR_dupprintf_000800b8)(PTR_DAT_00080134 + -0x1d68,iVar2);
    *param_2 = uVar4;
    (*(code *)PTR_safefree_000800c4)(iVar2);
    (*(code *)PTR_safefree_000800c4)(uVar1);
    iVar2 = 0;
  }
  return iVar2;
}

