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

void set_prof_file(char *file)

{
  undefined *puVar1;
  int __fd;
  int *piVar2;
  char *pcVar3;
  char *mesg;
  int iVar4;
  int iVar5;
  undefined4 *puVar6;
  
  __fd = devopen_simple(file,(char *)FUN_000aa4aa,true);
  puVar1 = PTR_stdout_000dcfc8;
  if (__fd == -1) {
    prof_fp = (FILE *)0x0;
    piVar2 = __errno_location();
    iVar4 = *piVar2;
    puVar6 = (undefined4 *)PTR_stderr_000dcf78;
  }
  else {
    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);
    puVar6 = (undefined4 *)PTR_stderr_000dcf78;
    piVar2 = (int *)puVar1;
    if ((iVar4 == __fd) ||
       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {
      prof_fp = (FILE *)*piVar2;
      if (prof_fp != (FILE *)0x0) {
        return;
      }
      piVar2 = __errno_location();
      iVar4 = *piVar2;
      puVar6 = (undefined4 *)PTR_stderr_000dcf78;
    }
    else {
      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);
      if (prof_fp != (FILE *)0x0) {
        return;
      }
      piVar2 = __errno_location();
      iVar4 = *piVar2;
    }
    iVar5 = fileno(*(FILE **)puVar1);
    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {
      close(__fd);
    }
  }
  *piVar2 = iVar4;
  set_loc("profile.c",0x6e);
  pcVar3 = strerror(*piVar2);
  mesg = (char *)dcgettext(0,"could not open `%s\' for writing: %s",5);
  r_warning(mesg,file,pcVar3);
  set_loc("profile.c",0x70);
  pcVar3 = (char *)dcgettext(0,"sending profile to standard error",5);
  r_warning(pcVar3);
  prof_fp = (FILE *)*puVar6;
  return;
}



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

void FUN_00078530(undefined4 param_1)

{
  undefined *puVar1;
  int __fd;
  int *piVar2;
  char *pcVar3;
  undefined4 uVar4;
  int iVar5;
  int iVar6;
  undefined4 *puVar7;
  
  __fd = FUN_0006e830(param_1,"w",1);
  puVar1 = PTR_stdout_000dcfc8;
  if (__fd == -1) {
    DAT_000e1924 = (FILE *)0x0;
    piVar2 = __errno_location();
    iVar5 = *piVar2;
    puVar7 = (undefined4 *)PTR_stderr_000dcf78;
  }
  else {
    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);
    puVar7 = (undefined4 *)PTR_stderr_000dcf78;
    piVar2 = (int *)puVar1;
    if ((iVar5 == __fd) ||
       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {
      DAT_000e1924 = (FILE *)*piVar2;
      if (DAT_000e1924 != (FILE *)0x0) {
        return;
      }
      piVar2 = __errno_location();
      iVar5 = *piVar2;
      puVar7 = (undefined4 *)PTR_stderr_000dcf78;
    }
    else {
      DAT_000e1924 = fdopen(__fd,"w");
      if (DAT_000e1924 != (FILE *)0x0) {
        return;
      }
      piVar2 = __errno_location();
      iVar5 = *piVar2;
    }
    iVar6 = fileno(*(FILE **)puVar1);
    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {
      close(__fd);
    }
  }
  *piVar2 = iVar5;
  FUN_00074330("profile.c",0x6e);
  pcVar3 = strerror(*piVar2);
  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);
  FUN_00074850(uVar4,param_1,pcVar3);
  FUN_00074330("profile.c",0x70);
  uVar4 = dcgettext(0,"sending profile to standard error",5);
  FUN_00074850(uVar4);
  DAT_000e1924 = (FILE *)*puVar7;
  return;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00016f80
ADD EBX,0x647ab
SUB ESP,0x20
LEA ESI,[EBX + 0xfffcd7c6]
PUSH 0x1
PUSH ESI
PUSH dword ptr [ESP + 0x3c]
CALL 0x0006e830
ADD ESP,0x10
CMP EAX,-0x1
JNZ 0x000785f0
MOV dword ptr [EBX + 0x4c40],0x0
CALL 0x00014330
MOV EDI,dword ptr [EBX + 0x294]
MOV ECX,dword ptr [EAX]
MOV ESI,EAX
LEA EBP,[EBX + 0xfffd15bc]
SUB ESP,0x8
MOV dword ptr [ESI],ECX
PUSH 0x6e
PUSH EBP
CALL 0x00074330
POP EAX
PUSH dword ptr [ESI]
CALL 0x00014180
MOV ESI,EAX
LEA EAX,[EBX + 0xfffc5540]
ADD ESP,0xc
PUSH 0x5
PUSH EAX
PUSH 0x0
CALL 0x00013f40
ADD ESP,0xc
PUSH ESI
PUSH dword ptr [ESP + 0x38]
PUSH EAX
CALL 0x00074850
POP EDX
POP ECX
PUSH 0x70
PUSH EBP
CALL 0x00074330
LEA EAX,[EBX + 0xfffd17ac]
ADD ESP,0xc
PUSH 0x5
PUSH EAX
PUSH 0x0
CALL 0x00013f40
MOV dword ptr [ESP],EAX
CALL 0x00074850
MOV EAX,dword ptr [EDI]
ADD ESP,0x10
MOV dword ptr [EBX + 0x4c40],EAX
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV EDI,dword ptr [EBX + 0x2e4]
SUB ESP,0xc
MOV EBP,EAX
MOV dword ptr [ESP + 0x14],EDI
PUSH dword ptr [EDI]
CALL 0x00014370
ADD ESP,0x10
CMP EAX,EBP
JZ 0x00078624
MOV EDI,dword ptr [EBX + 0x294]
SUB ESP,0xc
PUSH dword ptr [EDI]
CALL 0x00014370
ADD ESP,0x10
CMP EAX,EBP
JNZ 0x00078698
MOV EAX,dword ptr [EDI]
TEST EAX,EAX
MOV dword ptr [EBX + 0x4c40],EAX
JNZ 0x000785e7
CALL 0x00014330
MOV EDI,dword ptr [EBX + 0x294]
MOV ECX,dword ptr [EAX]
MOV ESI,EAX
MOV dword ptr [ESP + 0xc],ECX
SUB ESP,0xc
MOV EAX,dword ptr [ESP + 0x14]
PUSH dword ptr [EAX]
CALL 0x00014370
ADD ESP,0x10
CMP EAX,EBP
MOV ECX,dword ptr [ESP + 0xc]
JZ 0x00078579
MOV dword ptr [ESP + 0x8],ECX
SUB ESP,0xc
PUSH dword ptr [EDI]
CALL 0x00014370
ADD ESP,0x10
CMP EAX,EBP
MOV ECX,dword ptr [ESP + 0x8]
JZ 0x00078579
SUB ESP,0xc
PUSH EBP
CALL 0x000146d8
ADD ESP,0x10
MOV ECX,dword ptr [ESP + 0x8]
JMP 0x00078579
SUB ESP,0x8
PUSH ESI
PUSH EBP
CALL 0x000141c0
ADD ESP,0x10
TEST EAX,EAX
MOV dword ptr [EBX + 0x4c40],EAX
JNZ 0x000785e7
CALL 0x00014330
MOV ESI,EAX
MOV ECX,dword ptr [EAX]
JMP 0x0007863f
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_00078530(undefined4 param_1)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}\n\n" comment (function_definition "void FUN_00078530(undefined4 param_1)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}" primitive_type (function_declarator "FUN_00078530(undefined4 param_1)" identifier (parameter_list "(undefined4 param_1)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) ))) (compound_statement "{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int __fd;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "undefined4 *puVar7;" type_identifier (pointer_declarator "*puVar7" * identifier) ;) (expression_statement "__fd = FUN_0006e830(param_1,"w",1);" (assignment_expression "__fd = FUN_0006e830(param_1,"w",1)" identifier = (call_expression "FUN_0006e830(param_1,"w",1)" identifier (argument_list "(param_1,"w",1)" ( identifier , (string_literal ""w"" " string_content ") , number_literal )))) ;) (expression_statement "puVar1 = PTR_stdout_000dcfc8;" (assignment_expression "puVar1 = PTR_stdout_000dcfc8" identifier = identifier) ;) (if_statement "if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" if (parenthesized_expression "(__fd == -1)" ( (binary_expression "__fd == -1" identifier == number_literal) )) (compound_statement "{\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }" { (expression_statement "DAT_000e1924 = (FILE *)0x0;" (assignment_expression "DAT_000e1924 = (FILE *)0x0" identifier = (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) (else_clause "else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" else (compound_statement "{\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" { (expression_statement "iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);" (assignment_expression "iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8)" identifier = (call_expression "fileno(*(FILE **)PTR_stdout_000dcfc8)" identifier (argument_list "(*(FILE **)PTR_stdout_000dcfc8)" ( (pointer_expression "*(FILE **)PTR_stdout_000dcfc8" * (cast_expression "(FILE **)PTR_stdout_000dcfc8" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) ;) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "piVar2 = (int *)puVar1;" (assignment_expression "piVar2 = (int *)puVar1" identifier = (cast_expression "(int *)puVar1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (if_statement "if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" if (parenthesized_expression "((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd))" ( (binary_expression "(iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)" (parenthesized_expression "(iVar5 == __fd)" ( (binary_expression "iVar5 == __fd" identifier == identifier) )) || (parenthesized_expression "(iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)" ( (comma_expression "iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd" (assignment_expression "iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78)" identifier = (call_expression "fileno(*(FILE **)PTR_stderr_000dcf78)" identifier (argument_list "(*(FILE **)PTR_stderr_000dcf78)" ( (pointer_expression "*(FILE **)PTR_stderr_000dcf78" * (cast_expression "(FILE **)PTR_stderr_000dcf78" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) , (comma_expression "piVar2 = puVar7, iVar5 == __fd" (assignment_expression "piVar2 = puVar7" identifier = identifier) , (binary_expression "iVar5 == __fd" identifier == identifier))) ))) )) (compound_statement "{\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }" { (expression_statement "DAT_000e1924 = (FILE *)*piVar2;" (assignment_expression "DAT_000e1924 = (FILE *)*piVar2" identifier = (cast_expression "(FILE *)*piVar2" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar2" * identifier))) ;) (if_statement "if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }" if (parenthesized_expression "(DAT_000e1924 != (FILE *)0x0)" ( (binary_expression "DAT_000e1924 != (FILE *)0x0" identifier != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        return;\n      }" { (return_statement "return;" return ;) })) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) (else_clause "else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" else (compound_statement "{\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" { (expression_statement "DAT_000e1924 = fdopen(__fd,"w");" (assignment_expression "DAT_000e1924 = fdopen(__fd,"w")" identifier = (call_expression "fdopen(__fd,"w")" identifier (argument_list "(__fd,"w")" ( identifier , (string_literal ""w"" " string_content ") )))) ;) (if_statement "if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }" if (parenthesized_expression "(DAT_000e1924 != (FILE *)0x0)" ( (binary_expression "DAT_000e1924 != (FILE *)0x0" identifier != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        return;\n      }" { (return_statement "return;" return ;) })) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) }))) (expression_statement "iVar6 = fileno(*(FILE **)puVar1);" (assignment_expression "iVar6 = fileno(*(FILE **)puVar1)" identifier = (call_expression "fileno(*(FILE **)puVar1)" identifier (argument_list "(*(FILE **)puVar1)" ( (pointer_expression "*(FILE **)puVar1" * (cast_expression "(FILE **)puVar1" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) ;) (if_statement "if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }" if (parenthesized_expression "((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd))" ( (binary_expression "(iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)" (parenthesized_expression "(iVar6 != __fd)" ( (binary_expression "iVar6 != __fd" identifier != identifier) )) && (parenthesized_expression "(iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)" ( (comma_expression "iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd" (assignment_expression "iVar6 = fileno((FILE *)*puVar7)" identifier = (call_expression "fileno((FILE *)*puVar7)" identifier (argument_list "((FILE *)*puVar7)" ( (cast_expression "(FILE *)*puVar7" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar7" * identifier)) )))) , (binary_expression "iVar6 != __fd" identifier != identifier)) ))) )) (compound_statement "{\n      close(__fd);\n    }" { (expression_statement "close(__fd);" (call_expression "close(__fd)" identifier (argument_list "(__fd)" ( identifier ))) ;) })) }))) (expression_statement "*piVar2 = iVar5;" (assignment_expression "*piVar2 = iVar5" (pointer_expression "*piVar2" * identifier) = identifier) ;) (expression_statement "FUN_00074330("profile.c",0x6e);" (call_expression "FUN_00074330("profile.c",0x6e)" identifier (argument_list "("profile.c",0x6e)" ( (string_literal ""profile.c"" " string_content ") , number_literal ))) ;) (expression_statement "pcVar3 = strerror(*piVar2);" (assignment_expression "pcVar3 = strerror(*piVar2)" identifier = (call_expression "strerror(*piVar2)" identifier (argument_list "(*piVar2)" ( (pointer_expression "*piVar2" * identifier) )))) ;) (expression_statement "uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);" (assignment_expression "uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5)" identifier = (call_expression "dcgettext(0,"could not open `%s\' for writing: %s",5)" identifier (argument_list "(0,"could not open `%s\' for writing: %s",5)" ( number_literal , (string_literal ""could not open `%s\' for writing: %s"" " string_content escape_sequence string_content ") , number_literal )))) ;) (expression_statement "FUN_00074850(uVar4,param_1,pcVar3);" (call_expression "FUN_00074850(uVar4,param_1,pcVar3)" identifier (argument_list "(uVar4,param_1,pcVar3)" ( identifier , identifier , identifier ))) ;) (expression_statement "FUN_00074330("profile.c",0x70);" (call_expression "FUN_00074330("profile.c",0x70)" identifier (argument_list "("profile.c",0x70)" ( (string_literal ""profile.c"" " string_content ") , number_literal ))) ;) (expression_statement "uVar4 = dcgettext(0,"sending profile to standard error",5);" (assignment_expression "uVar4 = dcgettext(0,"sending profile to standard error",5)" identifier = (call_expression "dcgettext(0,"sending profile to standard error",5)" identifier (argument_list "(0,"sending profile to standard error",5)" ( number_literal , (string_literal ""sending profile to standard error"" " string_content ") , number_literal )))) ;) (expression_statement "FUN_00074850(uVar4);" (call_expression "FUN_00074850(uVar4)" identifier (argument_list "(uVar4)" ( identifier ))) ;) (expression_statement "DAT_000e1924 = (FILE *)*puVar7;" (assignment_expression "DAT_000e1924 = (FILE *)*puVar7" identifier = (cast_expression "(FILE *)*puVar7" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar7" * identifier))) ;) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nvoid set_prof_file(char *file)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  char *mesg;\n  int iVar4;\n  int iVar5;\n  undefined4 *puVar6;\n  \n  __fd = devopen_simple(file,(char *)FUN_000aa4aa,true);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    prof_fp = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar4 = *piVar2;\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }\n    iVar5 = fileno(*(FILE **)puVar1);\n    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar4;\n  set_loc("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  mesg = (char *)dcgettext(0,"could not open `%s\' for writing: %s",5);\n  r_warning(mesg,file,pcVar3);\n  set_loc("profile.c",0x70);\n  pcVar3 = (char *)dcgettext(0,"sending profile to standard error",5);\n  r_warning(pcVar3);\n  prof_fp = (FILE *)*puVar6;\n  return;\n}\n\n" comment comment (function_definition "void set_prof_file(char *file)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  char *mesg;\n  int iVar4;\n  int iVar5;\n  undefined4 *puVar6;\n  \n  __fd = devopen_simple(file,(char *)FUN_000aa4aa,true);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    prof_fp = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar4 = *piVar2;\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }\n    iVar5 = fileno(*(FILE **)puVar1);\n    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar4;\n  set_loc("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  mesg = (char *)dcgettext(0,"could not open `%s\' for writing: %s",5);\n  r_warning(mesg,file,pcVar3);\n  set_loc("profile.c",0x70);\n  pcVar3 = (char *)dcgettext(0,"sending profile to standard error",5);\n  r_warning(pcVar3);\n  prof_fp = (FILE *)*puVar6;\n  return;\n}" primitive_type (function_declarator "set_prof_file(char *file)" identifier (parameter_list "(char *file)" ( (parameter_declaration "char *file" primitive_type (pointer_declarator "*file" * identifier)) ))) (compound_statement "{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  char *mesg;\n  int iVar4;\n  int iVar5;\n  undefined4 *puVar6;\n  \n  __fd = devopen_simple(file,(char *)FUN_000aa4aa,true);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    prof_fp = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar4 = *piVar2;\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }\n    iVar5 = fileno(*(FILE **)puVar1);\n    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar4;\n  set_loc("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  mesg = (char *)dcgettext(0,"could not open `%s\' for writing: %s",5);\n  r_warning(mesg,file,pcVar3);\n  set_loc("profile.c",0x70);\n  pcVar3 = (char *)dcgettext(0,"sending profile to standard error",5);\n  r_warning(pcVar3);\n  prof_fp = (FILE *)*puVar6;\n  return;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int __fd;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "char *mesg;" primitive_type (pointer_declarator "*mesg" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "undefined4 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (expression_statement "__fd = devopen_simple(file,(char *)FUN_000aa4aa,true);" (assignment_expression "__fd = devopen_simple(file,(char *)FUN_000aa4aa,true)" identifier = (call_expression "devopen_simple(file,(char *)FUN_000aa4aa,true)" identifier (argument_list "(file,(char *)FUN_000aa4aa,true)" ( identifier , (cast_expression "(char *)FUN_000aa4aa" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier) , true )))) ;) (expression_statement "puVar1 = PTR_stdout_000dcfc8;" (assignment_expression "puVar1 = PTR_stdout_000dcfc8" identifier = identifier) ;) (if_statement "if (__fd == -1) {\n    prof_fp = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar4 = *piVar2;\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }\n    iVar5 = fileno(*(FILE **)puVar1);\n    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }\n  }" if (parenthesized_expression "(__fd == -1)" ( (binary_expression "__fd == -1" identifier == number_literal) )) (compound_statement "{\n    prof_fp = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar4 = *piVar2;\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n  }" { (expression_statement "prof_fp = (FILE *)0x0;" (assignment_expression "prof_fp = (FILE *)0x0" identifier = (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar4 = *piVar2;" (assignment_expression "iVar4 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) (expression_statement "puVar6 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar6 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) (else_clause "else {\n    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }\n    iVar5 = fileno(*(FILE **)puVar1);\n    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }\n  }" else (compound_statement "{\n    iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }\n    iVar5 = fileno(*(FILE **)puVar1);\n    if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }\n  }" { (expression_statement "iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8);" (assignment_expression "iVar4 = fileno(*(FILE **)PTR_stdout_000dcfc8)" identifier = (call_expression "fileno(*(FILE **)PTR_stdout_000dcfc8)" identifier (argument_list "(*(FILE **)PTR_stdout_000dcfc8)" ( (pointer_expression "*(FILE **)PTR_stdout_000dcfc8" * (cast_expression "(FILE **)PTR_stdout_000dcfc8" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) ;) (expression_statement "puVar6 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar6 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "piVar2 = (int *)puVar1;" (assignment_expression "piVar2 = (int *)puVar1" identifier = (cast_expression "(int *)puVar1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (if_statement "if ((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)) {\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }" if (parenthesized_expression "((iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd))" ( (binary_expression "(iVar4 == __fd) ||\n       (iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)" (parenthesized_expression "(iVar4 == __fd)" ( (binary_expression "iVar4 == __fd" identifier == identifier) )) || (parenthesized_expression "(iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd)" ( (comma_expression "iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar6, iVar4 == __fd" (assignment_expression "iVar4 = fileno(*(FILE **)PTR_stderr_000dcf78)" identifier = (call_expression "fileno(*(FILE **)PTR_stderr_000dcf78)" identifier (argument_list "(*(FILE **)PTR_stderr_000dcf78)" ( (pointer_expression "*(FILE **)PTR_stderr_000dcf78" * (cast_expression "(FILE **)PTR_stderr_000dcf78" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) , (comma_expression "piVar2 = puVar6, iVar4 == __fd" (assignment_expression "piVar2 = puVar6" identifier = identifier) , (binary_expression "iVar4 == __fd" identifier == identifier))) ))) )) (compound_statement "{\n      prof_fp = (FILE *)*piVar2;\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n      puVar6 = (undefined4 *)PTR_stderr_000dcf78;\n    }" { (expression_statement "prof_fp = (FILE *)*piVar2;" (assignment_expression "prof_fp = (FILE *)*piVar2" identifier = (cast_expression "(FILE *)*piVar2" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar2" * identifier))) ;) (if_statement "if (prof_fp != (FILE *)0x0) {\n        return;\n      }" if (parenthesized_expression "(prof_fp != (FILE *)0x0)" ( (binary_expression "prof_fp != (FILE *)0x0" identifier != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        return;\n      }" { (return_statement "return;" return ;) })) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar4 = *piVar2;" (assignment_expression "iVar4 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) (expression_statement "puVar6 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar6 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) (else_clause "else {\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }" else (compound_statement "{\n      prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);\n      if (prof_fp != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar4 = *piVar2;\n    }" { (expression_statement "prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa);" (assignment_expression "prof_fp = (FILE *)fdopen(__fd,(char *)FUN_000aa4aa)" identifier = (cast_expression "(FILE *)fdopen(__fd,(char *)FUN_000aa4aa)" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "fdopen(__fd,(char *)FUN_000aa4aa)" identifier (argument_list "(__fd,(char *)FUN_000aa4aa)" ( identifier , (cast_expression "(char *)FUN_000aa4aa" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier) ))))) ;) (if_statement "if (prof_fp != (FILE *)0x0) {\n        return;\n      }" if (parenthesized_expression "(prof_fp != (FILE *)0x0)" ( (binary_expression "prof_fp != (FILE *)0x0" identifier != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        return;\n      }" { (return_statement "return;" return ;) })) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar4 = *piVar2;" (assignment_expression "iVar4 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) }))) (expression_statement "iVar5 = fileno(*(FILE **)puVar1);" (assignment_expression "iVar5 = fileno(*(FILE **)puVar1)" identifier = (call_expression "fileno(*(FILE **)puVar1)" identifier (argument_list "(*(FILE **)puVar1)" ( (pointer_expression "*(FILE **)puVar1" * (cast_expression "(FILE **)puVar1" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) ;) (if_statement "if ((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)) {\n      close(__fd);\n    }" if (parenthesized_expression "((iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd))" ( (binary_expression "(iVar5 != __fd) && (iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)" (parenthesized_expression "(iVar5 != __fd)" ( (binary_expression "iVar5 != __fd" identifier != identifier) )) && (parenthesized_expression "(iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd)" ( (comma_expression "iVar5 = fileno((FILE *)*puVar6), iVar5 != __fd" (assignment_expression "iVar5 = fileno((FILE *)*puVar6)" identifier = (call_expression "fileno((FILE *)*puVar6)" identifier (argument_list "((FILE *)*puVar6)" ( (cast_expression "(FILE *)*puVar6" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar6" * identifier)) )))) , (binary_expression "iVar5 != __fd" identifier != identifier)) ))) )) (compound_statement "{\n      close(__fd);\n    }" { (expression_statement "close(__fd);" (call_expression "close(__fd)" identifier (argument_list "(__fd)" ( identifier ))) ;) })) }))) (expression_statement "*piVar2 = iVar4;" (assignment_expression "*piVar2 = iVar4" (pointer_expression "*piVar2" * identifier) = identifier) ;) (expression_statement "set_loc("profile.c",0x6e);" (call_expression "set_loc("profile.c",0x6e)" identifier (argument_list "("profile.c",0x6e)" ( (string_literal ""profile.c"" " string_content ") , number_literal ))) ;) (expression_statement "pcVar3 = strerror(*piVar2);" (assignment_expression "pcVar3 = strerror(*piVar2)" identifier = (call_expression "strerror(*piVar2)" identifier (argument_list "(*piVar2)" ( (pointer_expression "*piVar2" * identifier) )))) ;) (expression_statement "mesg = (char *)dcgettext(0,"could not open `%s\' for writing: %s",5);" (assignment_expression "mesg = (char *)dcgettext(0,"could not open `%s\' for writing: %s",5)" identifier = (cast_expression "(char *)dcgettext(0,"could not open `%s\' for writing: %s",5)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "dcgettext(0,"could not open `%s\' for writing: %s",5)" identifier (argument_list "(0,"could not open `%s\' for writing: %s",5)" ( number_literal , (string_literal ""could not open `%s\' for writing: %s"" " string_content escape_sequence string_content ") , number_literal ))))) ;) (expression_statement "r_warning(mesg,file,pcVar3);" (call_expression "r_warning(mesg,file,pcVar3)" identifier (argument_list "(mesg,file,pcVar3)" ( identifier , identifier , identifier ))) ;) (expression_statement "set_loc("profile.c",0x70);" (call_expression "set_loc("profile.c",0x70)" identifier (argument_list "("profile.c",0x70)" ( (string_literal ""profile.c"" " string_content ") , number_literal ))) ;) (expression_statement "pcVar3 = (char *)dcgettext(0,"sending profile to standard error",5);" (assignment_expression "pcVar3 = (char *)dcgettext(0,"sending profile to standard error",5)" identifier = (cast_expression "(char *)dcgettext(0,"sending profile to standard error",5)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "dcgettext(0,"sending profile to standard error",5)" identifier (argument_list "(0,"sending profile to standard error",5)" ( number_literal , (string_literal ""sending profile to standard error"" " string_content ") , number_literal ))))) ;) (expression_statement "r_warning(pcVar3);" (call_expression "r_warning(pcVar3)" identifier (argument_list "(pcVar3)" ( identifier ))) ;) (expression_statement "prof_fp = (FILE *)*puVar6;" (assignment_expression "prof_fp = (FILE *)*puVar6" identifier = (cast_expression "(FILE *)*puVar6" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar6" * identifier))) ;) (return_statement "return;" return ;) })))
(translation_unit "void FUN_00078530(undefined4 param_1)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}\n\n" (function_definition "void FUN_00078530(undefined4 param_1)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}" primitive_type (function_declarator "FUN_00078530(undefined4 param_1)" identifier (parameter_list "(undefined4 param_1)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) ))) (compound_statement "{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}" { (declaration "undefined *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int __fd;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "undefined4 *puVar7;" type_identifier (pointer_declarator "*puVar7" * identifier) ;) (expression_statement "__fd = FUN_0006e830(param_1,"w",1);" (assignment_expression "__fd = FUN_0006e830(param_1,"w",1)" identifier = (call_expression "FUN_0006e830(param_1,"w",1)" identifier (argument_list "(param_1,"w",1)" ( identifier , (string_literal ""w"" " string_content ") , number_literal )))) ;) (expression_statement "puVar1 = PTR_stdout_000dcfc8;" (assignment_expression "puVar1 = PTR_stdout_000dcfc8" identifier = identifier) ;) (if_statement "if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" if (parenthesized_expression "(__fd == -1)" ( (binary_expression "__fd == -1" identifier == number_literal) )) (compound_statement "{\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }" { (expression_statement "DAT_000e1924 = (FILE *)0x0;" (assignment_expression "DAT_000e1924 = (FILE *)0x0" identifier = (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) (else_clause "else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" else (compound_statement "{\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" { (expression_statement "iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);" (assignment_expression "iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8)" identifier = (call_expression "fileno(*(FILE **)PTR_stdout_000dcfc8)" identifier (argument_list "(*(FILE **)PTR_stdout_000dcfc8)" ( (pointer_expression "*(FILE **)PTR_stdout_000dcfc8" * (cast_expression "(FILE **)PTR_stdout_000dcfc8" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) ;) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) (expression_statement "piVar2 = (int *)puVar1;" (assignment_expression "piVar2 = (int *)puVar1" identifier = (cast_expression "(int *)puVar1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (if_statement "if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" if (parenthesized_expression "((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd))" ( (binary_expression "(iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)" (parenthesized_expression "(iVar5 == __fd)" ( (binary_expression "iVar5 == __fd" identifier == identifier) )) || (parenthesized_expression "(iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)" ( (comma_expression "iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd" (assignment_expression "iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78)" identifier = (call_expression "fileno(*(FILE **)PTR_stderr_000dcf78)" identifier (argument_list "(*(FILE **)PTR_stderr_000dcf78)" ( (pointer_expression "*(FILE **)PTR_stderr_000dcf78" * (cast_expression "(FILE **)PTR_stderr_000dcf78" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) , (comma_expression "piVar2 = puVar7, iVar5 == __fd" (assignment_expression "piVar2 = puVar7" identifier = identifier) , (binary_expression "iVar5 == __fd" identifier == identifier))) ))) )) (compound_statement "{\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }" { (expression_statement "DAT_000e1924 = (FILE *)*piVar2;" (assignment_expression "DAT_000e1924 = (FILE *)*piVar2" identifier = (cast_expression "(FILE *)*piVar2" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar2" * identifier))) ;) (if_statement "if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }" if (parenthesized_expression "(DAT_000e1924 != (FILE *)0x0)" ( (binary_expression "DAT_000e1924 != (FILE *)0x0" identifier != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        return;\n      }" { (return_statement "return;" return ;) })) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" identifier = (cast_expression "(undefined4 *)PTR_stderr_000dcf78" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) (else_clause "else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" else (compound_statement "{\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" { (expression_statement "DAT_000e1924 = fdopen(__fd,"w");" (assignment_expression "DAT_000e1924 = fdopen(__fd,"w")" identifier = (call_expression "fdopen(__fd,"w")" identifier (argument_list "(__fd,"w")" ( identifier , (string_literal ""w"" " string_content ") )))) ;) (if_statement "if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }" if (parenthesized_expression "(DAT_000e1924 != (FILE *)0x0)" ( (binary_expression "DAT_000e1924 != (FILE *)0x0" identifier != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        return;\n      }" { (return_statement "return;" return ;) })) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) ;) }))) (expression_statement "iVar6 = fileno(*(FILE **)puVar1);" (assignment_expression "iVar6 = fileno(*(FILE **)puVar1)" identifier = (call_expression "fileno(*(FILE **)puVar1)" identifier (argument_list "(*(FILE **)puVar1)" ( (pointer_expression "*(FILE **)puVar1" * (cast_expression "(FILE **)puVar1" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) )))) ;) (if_statement "if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }" if (parenthesized_expression "((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd))" ( (binary_expression "(iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)" (parenthesized_expression "(iVar6 != __fd)" ( (binary_expression "iVar6 != __fd" identifier != identifier) )) && (parenthesized_expression "(iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)" ( (comma_expression "iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd" (assignment_expression "iVar6 = fileno((FILE *)*puVar7)" identifier = (call_expression "fileno((FILE *)*puVar7)" identifier (argument_list "((FILE *)*puVar7)" ( (cast_expression "(FILE *)*puVar7" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar7" * identifier)) )))) , (binary_expression "iVar6 != __fd" identifier != identifier)) ))) )) (compound_statement "{\n      close(__fd);\n    }" { (expression_statement "close(__fd);" (call_expression "close(__fd)" identifier (argument_list "(__fd)" ( identifier ))) ;) })) }))) (expression_statement "*piVar2 = iVar5;" (assignment_expression "*piVar2 = iVar5" (pointer_expression "*piVar2" * identifier) = identifier) ;) (expression_statement "FUN_00074330("profile.c",0x6e);" (call_expression "FUN_00074330("profile.c",0x6e)" identifier (argument_list "("profile.c",0x6e)" ( (string_literal ""profile.c"" " string_content ") , number_literal ))) ;) (expression_statement "pcVar3 = strerror(*piVar2);" (assignment_expression "pcVar3 = strerror(*piVar2)" identifier = (call_expression "strerror(*piVar2)" identifier (argument_list "(*piVar2)" ( (pointer_expression "*piVar2" * identifier) )))) ;) (expression_statement "uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);" (assignment_expression "uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5)" identifier = (call_expression "dcgettext(0,"could not open `%s\' for writing: %s",5)" identifier (argument_list "(0,"could not open `%s\' for writing: %s",5)" ( number_literal , (string_literal ""could not open `%s\' for writing: %s"" " string_content escape_sequence string_content ") , number_literal )))) ;) (expression_statement "FUN_00074850(uVar4,param_1,pcVar3);" (call_expression "FUN_00074850(uVar4,param_1,pcVar3)" identifier (argument_list "(uVar4,param_1,pcVar3)" ( identifier , identifier , identifier ))) ;) (expression_statement "FUN_00074330("profile.c",0x70);" (call_expression "FUN_00074330("profile.c",0x70)" identifier (argument_list "("profile.c",0x70)" ( (string_literal ""profile.c"" " string_content ") , number_literal ))) ;) (expression_statement "uVar4 = dcgettext(0,"sending profile to standard error",5);" (assignment_expression "uVar4 = dcgettext(0,"sending profile to standard error",5)" identifier = (call_expression "dcgettext(0,"sending profile to standard error",5)" identifier (argument_list "(0,"sending profile to standard error",5)" ( number_literal , (string_literal ""sending profile to standard error"" " string_content ") , number_literal )))) ;) (expression_statement "FUN_00074850(uVar4);" (call_expression "FUN_00074850(uVar4)" identifier (argument_list "(uVar4)" ( identifier ))) ;) (expression_statement "DAT_000e1924 = (FILE *)*puVar7;" (assignment_expression "DAT_000e1924 = (FILE *)*puVar7" identifier = (cast_expression "(FILE *)*puVar7" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar7" * identifier))) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") , LIT )))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) IDENT)) )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT == IDENT) )) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) IDENT)) )))) , (comma_expression (assignment_expression IDENT = IDENT) , (binary_expression IDENT == IDENT))) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (return_statement return ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (return_statement return ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) }))) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) IDENT)) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != IDENT) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT)) )))) , (binary_expression IDENT != IDENT)) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) })) }))) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (call_expression IDENT (argument_list ( (string_literal " string_content ") , LIT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * IDENT) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , (string_literal " string_content escape_sequence string_content ") , LIT )))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( (string_literal " string_content ") , LIT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , (string_literal " string_content ") , LIT )))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (return_statement return ;) })))
(function_definition "void FUN_00078530(undefined4 param_1)\n\n{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}" (primitive_type "void") (function_declarator "FUN_00078530(undefined4 param_1)" (identifier "FUN_00078530") (parameter_list "(undefined4 param_1)" (( "(") (parameter_declaration "undefined4 param_1" (type_identifier "undefined4") (identifier "param_1")) () ")"))) (compound_statement "{\n  undefined *puVar1;\n  int __fd;\n  int *piVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  int iVar5;\n  int iVar6;\n  undefined4 *puVar7;\n  \n  __fd = FUN_0006e830(param_1,"w",1);\n  puVar1 = PTR_stdout_000dcfc8;\n  if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }\n  *piVar2 = iVar5;\n  FUN_00074330("profile.c",0x6e);\n  pcVar3 = strerror(*piVar2);\n  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);\n  FUN_00074850(uVar4,param_1,pcVar3);\n  FUN_00074330("profile.c",0x70);\n  uVar4 = dcgettext(0,"sending profile to standard error",5);\n  FUN_00074850(uVar4);\n  DAT_000e1924 = (FILE *)*puVar7;\n  return;\n}" ({ "{") (declaration "undefined *puVar1;" (type_identifier "undefined") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (declaration "int __fd;" (primitive_type "int") (identifier "__fd") (; ";")) (declaration "int *piVar2;" (primitive_type "int") (pointer_declarator "*piVar2" (* "*") (identifier "piVar2")) (; ";")) (declaration "char *pcVar3;" (primitive_type "char") (pointer_declarator "*pcVar3" (* "*") (identifier "pcVar3")) (; ";")) (declaration "undefined4 uVar4;" (type_identifier "undefined4") (identifier "uVar4") (; ";")) (declaration "int iVar5;" (primitive_type "int") (identifier "iVar5") (; ";")) (declaration "int iVar6;" (primitive_type "int") (identifier "iVar6") (; ";")) (declaration "undefined4 *puVar7;" (type_identifier "undefined4") (pointer_declarator "*puVar7" (* "*") (identifier "puVar7")) (; ";")) (expression_statement "__fd = FUN_0006e830(param_1,"w",1);" (assignment_expression "__fd = FUN_0006e830(param_1,"w",1)" (identifier "__fd") (= "=") (call_expression "FUN_0006e830(param_1,"w",1)" (identifier "FUN_0006e830") (argument_list "(param_1,"w",1)" (( "(") (identifier "param_1") (, ",") (string_literal ""w"" (" """) (string_content "w") (" """)) (, ",") (number_literal "1") () ")")))) (; ";")) (expression_statement "puVar1 = PTR_stdout_000dcfc8;" (assignment_expression "puVar1 = PTR_stdout_000dcfc8" (identifier "puVar1") (= "=") (identifier "PTR_stdout_000dcfc8")) (; ";")) (if_statement "if (__fd == -1) {\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }\n  else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" (if "if") (parenthesized_expression "(__fd == -1)" (( "(") (binary_expression "__fd == -1" (identifier "__fd") (== "==") (number_literal "-1")) () ")")) (compound_statement "{\n    DAT_000e1924 = (FILE *)0x0;\n    piVar2 = __errno_location();\n    iVar5 = *piVar2;\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n  }" ({ "{") (expression_statement "DAT_000e1924 = (FILE *)0x0;" (assignment_expression "DAT_000e1924 = (FILE *)0x0" (identifier "DAT_000e1924") (= "=") (cast_expression "(FILE *)0x0" (( "(") (type_descriptor "FILE *" (type_identifier "FILE") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" (identifier "piVar2") (= "=") (call_expression "__errno_location()" (identifier "__errno_location") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" (identifier "iVar5") (= "=") (pointer_expression "*piVar2" (* "*") (identifier "piVar2"))) (; ";")) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" (identifier "puVar7") (= "=") (cast_expression "(undefined4 *)PTR_stderr_000dcf78" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_stderr_000dcf78"))) (; ";")) (} "}")) (else_clause "else {\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" (else "else") (compound_statement "{\n    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);\n    puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    piVar2 = (int *)puVar1;\n    if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }\n    iVar6 = fileno(*(FILE **)puVar1);\n    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }\n  }" ({ "{") (expression_statement "iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);" (assignment_expression "iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8)" (identifier "iVar5") (= "=") (call_expression "fileno(*(FILE **)PTR_stdout_000dcfc8)" (identifier "fileno") (argument_list "(*(FILE **)PTR_stdout_000dcfc8)" (( "(") (pointer_expression "*(FILE **)PTR_stdout_000dcfc8" (* "*") (cast_expression "(FILE **)PTR_stdout_000dcfc8" (( "(") (type_descriptor "FILE **" (type_identifier "FILE") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (identifier "PTR_stdout_000dcfc8"))) () ")")))) (; ";")) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" (identifier "puVar7") (= "=") (cast_expression "(undefined4 *)PTR_stderr_000dcf78" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_stderr_000dcf78"))) (; ";")) (expression_statement "piVar2 = (int *)puVar1;" (assignment_expression "piVar2 = (int *)puVar1" (identifier "piVar2") (= "=") (cast_expression "(int *)puVar1" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "puVar1"))) (; ";")) (if_statement "if ((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }\n    else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" (if "if") (parenthesized_expression "((iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd))" (( "(") (binary_expression "(iVar5 == __fd) ||\n       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)" (parenthesized_expression "(iVar5 == __fd)" (( "(") (binary_expression "iVar5 == __fd" (identifier "iVar5") (== "==") (identifier "__fd")) () ")")) (|| "||") (parenthesized_expression "(iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)" (( "(") (comma_expression "iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd" (assignment_expression "iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78)" (identifier "iVar5") (= "=") (call_expression "fileno(*(FILE **)PTR_stderr_000dcf78)" (identifier "fileno") (argument_list "(*(FILE **)PTR_stderr_000dcf78)" (( "(") (pointer_expression "*(FILE **)PTR_stderr_000dcf78" (* "*") (cast_expression "(FILE **)PTR_stderr_000dcf78" (( "(") (type_descriptor "FILE **" (type_identifier "FILE") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (identifier "PTR_stderr_000dcf78"))) () ")")))) (, ",") (comma_expression "piVar2 = puVar7, iVar5 == __fd" (assignment_expression "piVar2 = puVar7" (identifier "piVar2") (= "=") (identifier "puVar7")) (, ",") (binary_expression "iVar5 == __fd" (identifier "iVar5") (== "==") (identifier "__fd")))) () ")"))) () ")")) (compound_statement "{\n      DAT_000e1924 = (FILE *)*piVar2;\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n      puVar7 = (undefined4 *)PTR_stderr_000dcf78;\n    }" ({ "{") (expression_statement "DAT_000e1924 = (FILE *)*piVar2;" (assignment_expression "DAT_000e1924 = (FILE *)*piVar2" (identifier "DAT_000e1924") (= "=") (cast_expression "(FILE *)*piVar2" (( "(") (type_descriptor "FILE *" (type_identifier "FILE") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*piVar2" (* "*") (identifier "piVar2")))) (; ";")) (if_statement "if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }" (if "if") (parenthesized_expression "(DAT_000e1924 != (FILE *)0x0)" (( "(") (binary_expression "DAT_000e1924 != (FILE *)0x0" (identifier "DAT_000e1924") (!= "!=") (cast_expression "(FILE *)0x0" (( "(") (type_descriptor "FILE *" (type_identifier "FILE") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n        return;\n      }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" (identifier "piVar2") (= "=") (call_expression "__errno_location()" (identifier "__errno_location") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" (identifier "iVar5") (= "=") (pointer_expression "*piVar2" (* "*") (identifier "piVar2"))) (; ";")) (expression_statement "puVar7 = (undefined4 *)PTR_stderr_000dcf78;" (assignment_expression "puVar7 = (undefined4 *)PTR_stderr_000dcf78" (identifier "puVar7") (= "=") (cast_expression "(undefined4 *)PTR_stderr_000dcf78" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_stderr_000dcf78"))) (; ";")) (} "}")) (else_clause "else {\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" (else "else") (compound_statement "{\n      DAT_000e1924 = fdopen(__fd,"w");\n      if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }\n      piVar2 = __errno_location();\n      iVar5 = *piVar2;\n    }" ({ "{") (expression_statement "DAT_000e1924 = fdopen(__fd,"w");" (assignment_expression "DAT_000e1924 = fdopen(__fd,"w")" (identifier "DAT_000e1924") (= "=") (call_expression "fdopen(__fd,"w")" (identifier "fdopen") (argument_list "(__fd,"w")" (( "(") (identifier "__fd") (, ",") (string_literal ""w"" (" """) (string_content "w") (" """)) () ")")))) (; ";")) (if_statement "if (DAT_000e1924 != (FILE *)0x0) {\n        return;\n      }" (if "if") (parenthesized_expression "(DAT_000e1924 != (FILE *)0x0)" (( "(") (binary_expression "DAT_000e1924 != (FILE *)0x0" (identifier "DAT_000e1924") (!= "!=") (cast_expression "(FILE *)0x0" (( "(") (type_descriptor "FILE *" (type_identifier "FILE") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n        return;\n      }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" (identifier "piVar2") (= "=") (call_expression "__errno_location()" (identifier "__errno_location") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "iVar5 = *piVar2;" (assignment_expression "iVar5 = *piVar2" (identifier "iVar5") (= "=") (pointer_expression "*piVar2" (* "*") (identifier "piVar2"))) (; ";")) (} "}")))) (expression_statement "iVar6 = fileno(*(FILE **)puVar1);" (assignment_expression "iVar6 = fileno(*(FILE **)puVar1)" (identifier "iVar6") (= "=") (call_expression "fileno(*(FILE **)puVar1)" (identifier "fileno") (argument_list "(*(FILE **)puVar1)" (( "(") (pointer_expression "*(FILE **)puVar1" (* "*") (cast_expression "(FILE **)puVar1" (( "(") (type_descriptor "FILE **" (type_identifier "FILE") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (identifier "puVar1"))) () ")")))) (; ";")) (if_statement "if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {\n      close(__fd);\n    }" (if "if") (parenthesized_expression "((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd))" (( "(") (binary_expression "(iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)" (parenthesized_expression "(iVar6 != __fd)" (( "(") (binary_expression "iVar6 != __fd" (identifier "iVar6") (!= "!=") (identifier "__fd")) () ")")) (&& "&&") (parenthesized_expression "(iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)" (( "(") (comma_expression "iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd" (assignment_expression "iVar6 = fileno((FILE *)*puVar7)" (identifier "iVar6") (= "=") (call_expression "fileno((FILE *)*puVar7)" (identifier "fileno") (argument_list "((FILE *)*puVar7)" (( "(") (cast_expression "(FILE *)*puVar7" (( "(") (type_descriptor "FILE *" (type_identifier "FILE") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*puVar7" (* "*") (identifier "puVar7"))) () ")")))) (, ",") (binary_expression "iVar6 != __fd" (identifier "iVar6") (!= "!=") (identifier "__fd"))) () ")"))) () ")")) (compound_statement "{\n      close(__fd);\n    }" ({ "{") (expression_statement "close(__fd);" (call_expression "close(__fd)" (identifier "close") (argument_list "(__fd)" (( "(") (identifier "__fd") () ")"))) (; ";")) (} "}"))) (} "}")))) (expression_statement "*piVar2 = iVar5;" (assignment_expression "*piVar2 = iVar5" (pointer_expression "*piVar2" (* "*") (identifier "piVar2")) (= "=") (identifier "iVar5")) (; ";")) (expression_statement "FUN_00074330("profile.c",0x6e);" (call_expression "FUN_00074330("profile.c",0x6e)" (identifier "FUN_00074330") (argument_list "("profile.c",0x6e)" (( "(") (string_literal ""profile.c"" (" """) (string_content "profile.c") (" """)) (, ",") (number_literal "0x6e") () ")"))) (; ";")) (expression_statement "pcVar3 = strerror(*piVar2);" (assignment_expression "pcVar3 = strerror(*piVar2)" (identifier "pcVar3") (= "=") (call_expression "strerror(*piVar2)" (identifier "strerror") (argument_list "(*piVar2)" (( "(") (pointer_expression "*piVar2" (* "*") (identifier "piVar2")) () ")")))) (; ";")) (expression_statement "uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);" (assignment_expression "uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5)" (identifier "uVar4") (= "=") (call_expression "dcgettext(0,"could not open `%s\' for writing: %s",5)" (identifier "dcgettext") (argument_list "(0,"could not open `%s\' for writing: %s",5)" (( "(") (number_literal "0") (, ",") (string_literal ""could not open `%s\' for writing: %s"" (" """) (string_content "could not open `%s") (escape_sequence "\'") (string_content " for writing: %s") (" """)) (, ",") (number_literal "5") () ")")))) (; ";")) (expression_statement "FUN_00074850(uVar4,param_1,pcVar3);" (call_expression "FUN_00074850(uVar4,param_1,pcVar3)" (identifier "FUN_00074850") (argument_list "(uVar4,param_1,pcVar3)" (( "(") (identifier "uVar4") (, ",") (identifier "param_1") (, ",") (identifier "pcVar3") () ")"))) (; ";")) (expression_statement "FUN_00074330("profile.c",0x70);" (call_expression "FUN_00074330("profile.c",0x70)" (identifier "FUN_00074330") (argument_list "("profile.c",0x70)" (( "(") (string_literal ""profile.c"" (" """) (string_content "profile.c") (" """)) (, ",") (number_literal "0x70") () ")"))) (; ";")) (expression_statement "uVar4 = dcgettext(0,"sending profile to standard error",5);" (assignment_expression "uVar4 = dcgettext(0,"sending profile to standard error",5)" (identifier "uVar4") (= "=") (call_expression "dcgettext(0,"sending profile to standard error",5)" (identifier "dcgettext") (argument_list "(0,"sending profile to standard error",5)" (( "(") (number_literal "0") (, ",") (string_literal ""sending profile to standard error"" (" """) (string_content "sending profile to standard error") (" """)) (, ",") (number_literal "5") () ")")))) (; ";")) (expression_statement "FUN_00074850(uVar4);" (call_expression "FUN_00074850(uVar4)" (identifier "FUN_00074850") (argument_list "(uVar4)" (( "(") (identifier "uVar4") () ")"))) (; ";")) (expression_statement "DAT_000e1924 = (FILE *)*puVar7;" (assignment_expression "DAT_000e1924 = (FILE *)*puVar7" (identifier "DAT_000e1924") (= "=") (cast_expression "(FILE *)*puVar7" (( "(") (type_descriptor "FILE *" (type_identifier "FILE") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*puVar7" (* "*") (identifier "puVar7")))) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

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

void function_1(char *file)

{
  type_1 *puVar1;
  int var_2;
  int *piVar2;
  char *pcVar3;
  char *mesg;
  int var_5;
  int var_8;
  type_2 *puVar6;
  
  var_2 = var_1(file,(char *)FUN_000aa4aa,true);
  puVar1 = PTR_stdout_000dcfc8;
  if (var_2 == -1) {
    var_6 = (type_3 *)0x0;
    piVar2 = var_3();
    var_5 = *piVar2;
    puVar6 = (type_2 *)PTR_stderr_000dcf78;
  }
  else {
    var_5 = var_4(*(type_3 **)PTR_stdout_000dcfc8);
    puVar6 = (type_2 *)PTR_stderr_000dcf78;
    piVar2 = (int *)puVar1;
    if ((var_5 == var_2) ||
       (var_5 = var_4(*(type_3 **)PTR_stderr_000dcf78), piVar2 = puVar6, var_5 == var_2)) {
      var_6 = (type_3 *)*piVar2;
      if (var_6 != (type_3 *)0x0) {
        return;
      }
      piVar2 = var_3();
      var_5 = *piVar2;
      puVar6 = (type_2 *)PTR_stderr_000dcf78;
    }
    else {
      var_6 = (type_3 *)var_7(var_2,(char *)FUN_000aa4aa);
      if (var_6 != (type_3 *)0x0) {
        return;
      }
      piVar2 = var_3();
      var_5 = *piVar2;
    }
    var_8 = var_4(*(type_3 **)puVar1);
    if ((var_8 != var_2) && (var_8 = var_4((type_3 *)*puVar6), var_8 != var_2)) {
      var_9(var_2);
    }
  }
  *piVar2 = var_5;
  var_10("profile.c",0x6e);
  pcVar3 = var_11(*piVar2);
  mesg = (char *)var_12(0,"could not open `%s\' for writing: %s",5);
  var_13(mesg,file,pcVar3);
  var_10("profile.c",0x70);
  pcVar3 = (char *)var_12(0,"sending profile to standard error",5);
  var_13(pcVar3);
  var_6 = (type_3 *)*puVar6;
  return;
}


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

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

void MASKED(undefined4 param_1)

{
  undefined *puVar1;
  int __fd;
  int *piVar2;
  char *pcVar3;
  undefined4 uVar4;
  int iVar5;
  int iVar6;
  undefined4 *puVar7;
  
  __fd = FUN_0006e830(param_1,"w",1);
  puVar1 = PTR_stdout_000dcfc8;
  if (__fd == -1) {
    DAT_000e1924 = (FILE *)0x0;
    piVar2 = __errno_location();
    iVar5 = *piVar2;
    puVar7 = (undefined4 *)PTR_stderr_000dcf78;
  }
  else {
    iVar5 = fileno(*(FILE **)PTR_stdout_000dcfc8);
    puVar7 = (undefined4 *)PTR_stderr_000dcf78;
    piVar2 = (int *)puVar1;
    if ((iVar5 == __fd) ||
       (iVar5 = fileno(*(FILE **)PTR_stderr_000dcf78), piVar2 = puVar7, iVar5 == __fd)) {
      DAT_000e1924 = (FILE *)*piVar2;
      if (DAT_000e1924 != (FILE *)0x0) {
        return;
      }
      piVar2 = __errno_location();
      iVar5 = *piVar2;
      puVar7 = (undefined4 *)PTR_stderr_000dcf78;
    }
    else {
      DAT_000e1924 = fdopen(__fd,"w");
      if (DAT_000e1924 != (FILE *)0x0) {
        return;
      }
      piVar2 = __errno_location();
      iVar5 = *piVar2;
    }
    iVar6 = fileno(*(FILE **)puVar1);
    if ((iVar6 != __fd) && (iVar6 = fileno((FILE *)*puVar7), iVar6 != __fd)) {
      close(__fd);
    }
  }
  *piVar2 = iVar5;
  FUN_00074330("profile.c",0x6e);
  pcVar3 = strerror(*piVar2);
  uVar4 = dcgettext(0,"could not open `%s\' for writing: %s",5);
  FUN_00074850(uVar4,param_1,pcVar3);
  FUN_00074330("profile.c",0x70);
  uVar4 = dcgettext(0,"sending profile to standard error",5);
  FUN_00074850(uVar4);
  DAT_000e1924 = (FILE *)*puVar7;
  return;
}

