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

int c_stack_action(_func_void_int *action)

{
  int iVar1;
  int *piVar2;
  
  if (action == (_func_void_int *)0x0) {
    action = null_action;
  }
  segv_action = action;
  program_error_message = (char *)dcgettext(0,"program error",5);
  stack_overflow_message = (char *)dcgettext(0,"stack overflow",5);
  iVar1 = stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000);
  if (iVar1 == 0) {
    segv_handler_missing = sigsegv_install_handler(segv_handler);
    iVar1 = 0;
  }
  else {
    piVar2 = __errno_location();
    iVar1 = -1;
    *piVar2 = 0x5f;
  }
  return iVar1;
}



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

undefined4 FUN_0001f320(code *param_1)

{
  int iVar1;
  int *piVar2;
  undefined4 uVar3;
  
  DAT_0004c368 = param_1;
  if (param_1 == (code *)0x0) {
    DAT_0004c368 = FUN_0001f1b0;
  }
  DAT_0004c364 = dcgettext(0,"program error",5);
  DAT_0004c360 = dcgettext(0,"stack overflow",5);
  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);
  if (iVar1 == 0) {
    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);
    uVar3 = 0;
  }
  else {
    piVar2 = __errno_location();
    uVar3 = 0xffffffff;
    *piVar2 = 0x5f;
  }
  return uVar3;
}


PUSH ESI
PUSH EBX
CALL 0x000142a0
ADD EBX,0x28ac5
SUB ESP,0x8
MOV EAX,dword ptr [ESP + 0x14]
PUSH 0x5
TEST EAX,EAX
LEA EDX,[EBX + 0xfffd73c4]
CMOVZ EAX,EDX
MOV dword ptr [EBX + 0x457c],EAX
LEA EAX,[EBX + 0xffff2e70]
PUSH EAX
PUSH 0x0
CALL 0x00012180
ADD ESP,0xc
MOV dword ptr [EBX + 0x4578],EAX
LEA EAX,[EBX + 0xffff2e7e]
PUSH 0x5
PUSH EAX
PUSH 0x0
CALL 0x00012180
ADD ESP,0xc
MOV dword ptr [EBX + 0x4574],EAX
LEA EAX,[EBX + 0x574]
PUSH 0x4000
PUSH EAX
LEA EAX,[EBX + 0xfffd7504]
PUSH EAX
CALL 0x00012480
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x0001f3c0
SUB ESP,0xc
MOV ESI,EAX
LEA EAX,[EBX + 0xfffd74e4]
PUSH EAX
CALL 0x000124c0
ADD ESP,0x10
MOV dword ptr [EBX + 0x554],EAX
ADD ESP,0x4
MOV EAX,ESI
POP EBX
POP ESI
RET
CALL 0x00012450
MOV ESI,0xffffffff
MOV dword ptr [EAX],0x5f
JMP 0x0001f3b0
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 FUN_0001f320(code *param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}\n\n" comment (function_definition "undefined4 FUN_0001f320(code *param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}" type_identifier (function_declarator "FUN_0001f320(code *param_1)" identifier (parameter_list "(code *param_1)" ( (parameter_declaration "code *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "undefined4 uVar3;" type_identifier identifier ;) (expression_statement "DAT_0004c368 = param_1;" (assignment_expression "DAT_0004c368 = param_1" identifier = identifier) ;) (if_statement "if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }" if (parenthesized_expression "(param_1 == (code *)0x0)" ( (binary_expression "param_1 == (code *)0x0" identifier == (cast_expression "(code *)0x0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    DAT_0004c368 = FUN_0001f1b0;\n  }" { (expression_statement "DAT_0004c368 = FUN_0001f1b0;" (assignment_expression "DAT_0004c368 = FUN_0001f1b0" identifier = identifier) ;) })) (expression_statement "DAT_0004c364 = dcgettext(0,"program error",5);" (assignment_expression "DAT_0004c364 = dcgettext(0,"program error",5)" identifier = (call_expression "dcgettext(0,"program error",5)" identifier (argument_list "(0,"program error",5)" ( number_literal , (string_literal ""program error"" " string_content ") , number_literal )))) ;) (expression_statement "DAT_0004c360 = dcgettext(0,"stack overflow",5);" (assignment_expression "DAT_0004c360 = dcgettext(0,"stack overflow",5)" identifier = (call_expression "dcgettext(0,"stack overflow",5)" identifier (argument_list "(0,"stack overflow",5)" ( number_literal , (string_literal ""stack overflow"" " string_content ") , number_literal )))) ;) (expression_statement "iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);" (assignment_expression "iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000)" identifier = (call_expression "stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000)" identifier (argument_list "(FUN_0001f2f0,&DAT_00048360,0x4000)" ( identifier , (pointer_expression "&DAT_00048360" & identifier) , number_literal )))) ;) (if_statement "if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }" { (expression_statement "DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);" (assignment_expression "DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0)" identifier = (call_expression "sigsegv_install_handler(FUN_0001f2d0)" identifier (argument_list "(FUN_0001f2d0)" ( identifier )))) ;) (expression_statement "uVar3 = 0;" (assignment_expression "uVar3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" else (compound_statement "{\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" { (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "uVar3 = 0xffffffff;" (assignment_expression "uVar3 = 0xffffffff" identifier = number_literal) ;) (expression_statement "*piVar2 = 0x5f;" (assignment_expression "*piVar2 = 0x5f" (pointer_expression "*piVar2" * identifier) = number_literal) ;) }))) (return_statement "return uVar3;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nint c_stack_action(_func_void_int *action)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (action == (_func_void_int *)0x0) {\n    action = null_action;\n  }\n  segv_action = action;\n  program_error_message = (char *)dcgettext(0,"program error",5);\n  stack_overflow_message = (char *)dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000);\n  if (iVar1 == 0) {\n    segv_handler_missing = sigsegv_install_handler(segv_handler);\n    iVar1 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    iVar1 = -1;\n    *piVar2 = 0x5f;\n  }\n  return iVar1;\n}\n\n" comment comment (function_definition "int c_stack_action(_func_void_int *action)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (action == (_func_void_int *)0x0) {\n    action = null_action;\n  }\n  segv_action = action;\n  program_error_message = (char *)dcgettext(0,"program error",5);\n  stack_overflow_message = (char *)dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000);\n  if (iVar1 == 0) {\n    segv_handler_missing = sigsegv_install_handler(segv_handler);\n    iVar1 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    iVar1 = -1;\n    *piVar2 = 0x5f;\n  }\n  return iVar1;\n}" primitive_type (function_declarator "c_stack_action(_func_void_int *action)" identifier (parameter_list "(_func_void_int *action)" ( (parameter_declaration "_func_void_int *action" type_identifier (pointer_declarator "*action" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (action == (_func_void_int *)0x0) {\n    action = null_action;\n  }\n  segv_action = action;\n  program_error_message = (char *)dcgettext(0,"program error",5);\n  stack_overflow_message = (char *)dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000);\n  if (iVar1 == 0) {\n    segv_handler_missing = sigsegv_install_handler(segv_handler);\n    iVar1 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    iVar1 = -1;\n    *piVar2 = 0x5f;\n  }\n  return iVar1;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (if_statement "if (action == (_func_void_int *)0x0) {\n    action = null_action;\n  }" if (parenthesized_expression "(action == (_func_void_int *)0x0)" ( (binary_expression "action == (_func_void_int *)0x0" identifier == (cast_expression "(_func_void_int *)0x0" ( (type_descriptor "_func_void_int *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    action = null_action;\n  }" { (expression_statement "action = null_action;" (assignment_expression "action = null_action" identifier = identifier) ;) })) (expression_statement "segv_action = action;" (assignment_expression "segv_action = action" identifier = identifier) ;) (expression_statement "program_error_message = (char *)dcgettext(0,"program error",5);" (assignment_expression "program_error_message = (char *)dcgettext(0,"program error",5)" identifier = (cast_expression "(char *)dcgettext(0,"program error",5)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "dcgettext(0,"program error",5)" identifier (argument_list "(0,"program error",5)" ( number_literal , (string_literal ""program error"" " string_content ") , number_literal ))))) ;) (expression_statement "stack_overflow_message = (char *)dcgettext(0,"stack overflow",5);" (assignment_expression "stack_overflow_message = (char *)dcgettext(0,"stack overflow",5)" identifier = (cast_expression "(char *)dcgettext(0,"stack overflow",5)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "dcgettext(0,"stack overflow",5)" identifier (argument_list "(0,"stack overflow",5)" ( number_literal , (string_literal ""stack overflow"" " string_content ") , number_literal ))))) ;) (expression_statement "iVar1 = stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000);" (assignment_expression "iVar1 = stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000)" identifier = (call_expression "stackoverflow_install_handler(overflow_handler,&alternate_signal_stack,0x4000)" identifier (argument_list "(overflow_handler,&alternate_signal_stack,0x4000)" ( identifier , (pointer_expression "&alternate_signal_stack" & identifier) , number_literal )))) ;) (if_statement "if (iVar1 == 0) {\n    segv_handler_missing = sigsegv_install_handler(segv_handler);\n    iVar1 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    iVar1 = -1;\n    *piVar2 = 0x5f;\n  }" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    segv_handler_missing = sigsegv_install_handler(segv_handler);\n    iVar1 = 0;\n  }" { (expression_statement "segv_handler_missing = sigsegv_install_handler(segv_handler);" (assignment_expression "segv_handler_missing = sigsegv_install_handler(segv_handler)" identifier = (call_expression "sigsegv_install_handler(segv_handler)" identifier (argument_list "(segv_handler)" ( identifier )))) ;) (expression_statement "iVar1 = 0;" (assignment_expression "iVar1 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    piVar2 = __errno_location();\n    iVar1 = -1;\n    *piVar2 = 0x5f;\n  }" else (compound_statement "{\n    piVar2 = __errno_location();\n    iVar1 = -1;\n    *piVar2 = 0x5f;\n  }" { (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar1 = -1;" (assignment_expression "iVar1 = -1" identifier = number_literal) ;) (expression_statement "*piVar2 = 0x5f;" (assignment_expression "*piVar2 = 0x5f" (pointer_expression "*piVar2" * identifier) = number_literal) ;) }))) (return_statement "return iVar1;" return identifier ;) })))
(translation_unit "undefined4 FUN_0001f320(code *param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}\n\n" (function_definition "undefined4 FUN_0001f320(code *param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}" type_identifier (function_declarator "FUN_0001f320(code *param_1)" identifier (parameter_list "(code *param_1)" ( (parameter_declaration "code *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "undefined4 uVar3;" type_identifier identifier ;) (expression_statement "DAT_0004c368 = param_1;" (assignment_expression "DAT_0004c368 = param_1" identifier = identifier) ;) (if_statement "if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }" if (parenthesized_expression "(param_1 == (code *)0x0)" ( (binary_expression "param_1 == (code *)0x0" identifier == (cast_expression "(code *)0x0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    DAT_0004c368 = FUN_0001f1b0;\n  }" { (expression_statement "DAT_0004c368 = FUN_0001f1b0;" (assignment_expression "DAT_0004c368 = FUN_0001f1b0" identifier = identifier) ;) })) (expression_statement "DAT_0004c364 = dcgettext(0,"program error",5);" (assignment_expression "DAT_0004c364 = dcgettext(0,"program error",5)" identifier = (call_expression "dcgettext(0,"program error",5)" identifier (argument_list "(0,"program error",5)" ( number_literal , (string_literal ""program error"" " string_content ") , number_literal )))) ;) (expression_statement "DAT_0004c360 = dcgettext(0,"stack overflow",5);" (assignment_expression "DAT_0004c360 = dcgettext(0,"stack overflow",5)" identifier = (call_expression "dcgettext(0,"stack overflow",5)" identifier (argument_list "(0,"stack overflow",5)" ( number_literal , (string_literal ""stack overflow"" " string_content ") , number_literal )))) ;) (expression_statement "iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);" (assignment_expression "iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000)" identifier = (call_expression "stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000)" identifier (argument_list "(FUN_0001f2f0,&DAT_00048360,0x4000)" ( identifier , (pointer_expression "&DAT_00048360" & identifier) , number_literal )))) ;) (if_statement "if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }" { (expression_statement "DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);" (assignment_expression "DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0)" identifier = (call_expression "sigsegv_install_handler(FUN_0001f2d0)" identifier (argument_list "(FUN_0001f2d0)" ( identifier )))) ;) (expression_statement "uVar3 = 0;" (assignment_expression "uVar3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" else (compound_statement "{\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" { (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" identifier = (call_expression "__errno_location()" identifier (argument_list "()" ( )))) ;) (expression_statement "uVar3 = 0xffffffff;" (assignment_expression "uVar3 = 0xffffffff" identifier = number_literal) ;) (expression_statement "*piVar2 = 0x5f;" (assignment_expression "*piVar2 = 0x5f" (pointer_expression "*piVar2" * identifier) = number_literal) ;) }))) (return_statement "return uVar3;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , (string_literal " string_content ") , LIT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT , (string_literal " string_content ") , LIT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) }))) (return_statement return IDENT ;) })))
(function_definition "undefined4 FUN_0001f320(code *param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}" (type_identifier "undefined4") (function_declarator "FUN_0001f320(code *param_1)" (identifier "FUN_0001f320") (parameter_list "(code *param_1)" (( "(") (parameter_declaration "code *param_1" (type_identifier "code") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) () ")"))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  \n  DAT_0004c368 = param_1;\n  if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }\n  DAT_0004c364 = dcgettext(0,"program error",5);\n  DAT_0004c360 = dcgettext(0,"stack overflow",5);\n  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);\n  if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }\n  return uVar3;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int *piVar2;" (primitive_type "int") (pointer_declarator "*piVar2" (* "*") (identifier "piVar2")) (; ";")) (declaration "undefined4 uVar3;" (type_identifier "undefined4") (identifier "uVar3") (; ";")) (expression_statement "DAT_0004c368 = param_1;" (assignment_expression "DAT_0004c368 = param_1" (identifier "DAT_0004c368") (= "=") (identifier "param_1")) (; ";")) (if_statement "if (param_1 == (code *)0x0) {\n    DAT_0004c368 = FUN_0001f1b0;\n  }" (if "if") (parenthesized_expression "(param_1 == (code *)0x0)" (( "(") (binary_expression "param_1 == (code *)0x0" (identifier "param_1") (== "==") (cast_expression "(code *)0x0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    DAT_0004c368 = FUN_0001f1b0;\n  }" ({ "{") (expression_statement "DAT_0004c368 = FUN_0001f1b0;" (assignment_expression "DAT_0004c368 = FUN_0001f1b0" (identifier "DAT_0004c368") (= "=") (identifier "FUN_0001f1b0")) (; ";")) (} "}"))) (expression_statement "DAT_0004c364 = dcgettext(0,"program error",5);" (assignment_expression "DAT_0004c364 = dcgettext(0,"program error",5)" (identifier "DAT_0004c364") (= "=") (call_expression "dcgettext(0,"program error",5)" (identifier "dcgettext") (argument_list "(0,"program error",5)" (( "(") (number_literal "0") (, ",") (string_literal ""program error"" (" """) (string_content "program error") (" """)) (, ",") (number_literal "5") () ")")))) (; ";")) (expression_statement "DAT_0004c360 = dcgettext(0,"stack overflow",5);" (assignment_expression "DAT_0004c360 = dcgettext(0,"stack overflow",5)" (identifier "DAT_0004c360") (= "=") (call_expression "dcgettext(0,"stack overflow",5)" (identifier "dcgettext") (argument_list "(0,"stack overflow",5)" (( "(") (number_literal "0") (, ",") (string_literal ""stack overflow"" (" """) (string_content "stack overflow") (" """)) (, ",") (number_literal "5") () ")")))) (; ";")) (expression_statement "iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);" (assignment_expression "iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000)" (identifier "iVar1") (= "=") (call_expression "stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000)" (identifier "stackoverflow_install_handler") (argument_list "(FUN_0001f2f0,&DAT_00048360,0x4000)" (( "(") (identifier "FUN_0001f2f0") (, ",") (pointer_expression "&DAT_00048360" (& "&") (identifier "DAT_00048360")) (, ",") (number_literal "0x4000") () ")")))) (; ";")) (if_statement "if (iVar1 == 0) {\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }\n  else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" (if "if") (parenthesized_expression "(iVar1 == 0)" (( "(") (binary_expression "iVar1 == 0" (identifier "iVar1") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);\n    uVar3 = 0;\n  }" ({ "{") (expression_statement "DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);" (assignment_expression "DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0)" (identifier "DAT_00048340") (= "=") (call_expression "sigsegv_install_handler(FUN_0001f2d0)" (identifier "sigsegv_install_handler") (argument_list "(FUN_0001f2d0)" (( "(") (identifier "FUN_0001f2d0") () ")")))) (; ";")) (expression_statement "uVar3 = 0;" (assignment_expression "uVar3 = 0" (identifier "uVar3") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" (else "else") (compound_statement "{\n    piVar2 = __errno_location();\n    uVar3 = 0xffffffff;\n    *piVar2 = 0x5f;\n  }" ({ "{") (expression_statement "piVar2 = __errno_location();" (assignment_expression "piVar2 = __errno_location()" (identifier "piVar2") (= "=") (call_expression "__errno_location()" (identifier "__errno_location") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "uVar3 = 0xffffffff;" (assignment_expression "uVar3 = 0xffffffff" (identifier "uVar3") (= "=") (number_literal "0xffffffff")) (; ";")) (expression_statement "*piVar2 = 0x5f;" (assignment_expression "*piVar2 = 0x5f" (pointer_expression "*piVar2" (* "*") (identifier "piVar2")) (= "=") (number_literal "0x5f")) (; ";")) (} "}")))) (return_statement "return uVar3;" (return "return") (identifier "uVar3") (; ";")) (} "}")))

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

int function_1(type_1 *var_1)

{
  int var_4;
  int *piVar2;
  
  if (var_1 == (type_1 *)0x0) {
    var_1 = null_action;
  }
  segv_action = var_1;
  program_error_message = (char *)var_2(0,"program error",5);
  stack_overflow_message = (char *)var_2(0,"stack overflow",5);
  var_4 = var_3(overflow_handler,&alternate_signal_stack,0x4000);
  if (var_4 == 0) {
    segv_handler_missing = var_5(segv_handler);
    var_4 = 0;
  }
  else {
    piVar2 = var_6();
    var_4 = -1;
    *piVar2 = 0x5f;
  }
  return var_4;
}


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

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

undefined4 MASKED(code *param_1)

{
  int iVar1;
  int *piVar2;
  undefined4 uVar3;
  
  DAT_0004c368 = param_1;
  if (param_1 == (code *)0x0) {
    DAT_0004c368 = FUN_0001f1b0;
  }
  DAT_0004c364 = dcgettext(0,"program error",5);
  DAT_0004c360 = dcgettext(0,"stack overflow",5);
  iVar1 = stackoverflow_install_handler(FUN_0001f2f0,&DAT_00048360,0x4000);
  if (iVar1 == 0) {
    DAT_00048340 = sigsegv_install_handler(FUN_0001f2d0);
    uVar3 = 0;
  }
  else {
    piVar2 = __errno_location();
    uVar3 = 0xffffffff;
    *piVar2 = 0x5f;
  }
  return uVar3;
}

