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

void minfo(char *fmt,...)

{
  asneeded_minfo *paVar1;
  char *in_stack_00000008;
  bfd *in_stack_0000000c;
  char *in_stack_00000010;
  
  if (config.map_file != (FILE *)0x0) {
    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {
      paVar1 = (asneeded_minfo *)xmalloc(0x10);
      paVar1->next = (asneeded_minfo *)0x0;
      paVar1->soname = in_stack_00000008;
      paVar1->ref = in_stack_0000000c;
      paVar1->name = in_stack_00000010;
      *asneeded_list_tail = paVar1;
      asneeded_list_tail = (asneeded_minfo **)paVar1;
    }
    else {
      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);
    }
  }
  return;
}



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

void FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)

{
  undefined4 *puVar1;
  
  if (DAT_0008cd50 != 0) {
    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {
      puVar1 = (undefined4 *)xmalloc(0x10);
      *puVar1 = 0;
      puVar1[1] = param_2;
      puVar1[2] = param_3;
      puVar1[3] = param_4;
      *DAT_0008cba0 = puVar1;
      DAT_0008cba0 = puVar1;
    }
    else {
      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);
    }
  }
  return;
}


PUSH ESI
PUSH EBX
CALL 0x00015a20
ADD EBX,0x5a869
SUB ESP,0x4
MOV EDX,dword ptr [ESP + 0x10]
LEA EAX,[EBX + 0xd00]
MOV ECX,dword ptr [EAX + 0x50]
TEST ECX,ECX
JZ 0x000317cf
CMP byte ptr [EDX],0x25
LEA ESI,[ESP + 0x14]
JNZ 0x000317c0
CMP byte ptr [EDX + 0x1],0x21
JZ 0x000317d8
PUSH 0x0
PUSH ESI
PUSH EDX
PUSH dword ptr [EAX + 0x50]
CALL 0x000308a0
ADD ESP,0x10
ADD ESP,0x4
POP EBX
POP ESI
RET
CMP byte ptr [EDX + 0x2],0x0
JNZ 0x000317c0
SUB ESP,0xc
PUSH 0x10
CALL 0x00014c68
MOV EDX,dword ptr [ESI]
ADD ESP,0x10
MOV dword ptr [EAX],0x0
MOV dword ptr [EAX + 0x4],EDX
MOV EDX,dword ptr [ESI + 0x4]
MOV dword ptr [EAX + 0x8],EDX
MOV EDX,dword ptr [ESI + 0x8]
MOV dword ptr [EAX + 0xc],EDX
LEA EDX,[EBX + 0xba0]
MOV ECX,dword ptr [EDX]
MOV dword ptr [ECX],EAX
MOV dword ptr [EDX],EAX
JMP 0x000317cf
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)\n\n{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}\n\n" comment (function_definition "void FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)\n\n{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}" primitive_type (function_declarator "FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)" identifier (parameter_list "(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) ))) (compound_statement "{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}" { (declaration "undefined4 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (if_statement "if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }" if (parenthesized_expression "(DAT_0008cd50 != 0)" ( (binary_expression "DAT_0008cd50 != 0" identifier != number_literal) )) (compound_statement "{\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }" { (if_statement "if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" if (parenthesized_expression "(((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0'))" ( (binary_expression "((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')" (parenthesized_expression "((*param_1 == '%') && (param_1[1] == '!'))" ( (binary_expression "(*param_1 == '%') && (param_1[1] == '!')" (parenthesized_expression "(*param_1 == '%')" ( (binary_expression "*param_1 == '%'" (pointer_expression "*param_1" * identifier) == (char_literal "'%'" ' character ')) )) && (parenthesized_expression "(param_1[1] == '!')" ( (binary_expression "param_1[1] == '!'" (subscript_expression "param_1[1]" identifier [ number_literal ]) == (char_literal "'!'" ' character ')) ))) )) && (parenthesized_expression "(param_1[2] == '\0')" ( (binary_expression "param_1[2] == '\0'" (subscript_expression "param_1[2]" identifier [ number_literal ]) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }" { (expression_statement "puVar1 = (undefined4 *)xmalloc(0x10);" (assignment_expression "puVar1 = (undefined4 *)xmalloc(0x10)" identifier = (cast_expression "(undefined4 *)xmalloc(0x10)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(0x10)" identifier (argument_list "(0x10)" ( number_literal ))))) ;) (expression_statement "*puVar1 = 0;" (assignment_expression "*puVar1 = 0" (pointer_expression "*puVar1" * identifier) = number_literal) ;) (expression_statement "puVar1[1] = param_2;" (assignment_expression "puVar1[1] = param_2" (subscript_expression "puVar1[1]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar1[2] = param_3;" (assignment_expression "puVar1[2] = param_3" (subscript_expression "puVar1[2]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar1[3] = param_4;" (assignment_expression "puVar1[3] = param_4" (subscript_expression "puVar1[3]" identifier [ number_literal ]) = identifier) ;) (expression_statement "*DAT_0008cba0 = puVar1;" (assignment_expression "*DAT_0008cba0 = puVar1" (pointer_expression "*DAT_0008cba0" * identifier) = identifier) ;) (expression_statement "DAT_0008cba0 = puVar1;" (assignment_expression "DAT_0008cba0 = puVar1" identifier = identifier) ;) }) (else_clause "else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" else (compound_statement "{\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" { (expression_statement "FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);" (call_expression "FUN_000308a0(DAT_0008cd50,param_1,&param_2,0)" identifier (argument_list "(DAT_0008cd50,param_1,&param_2,0)" ( identifier , identifier , (pointer_expression "&param_2" & identifier) , number_literal ))) ;) }))) })) (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 minfo(char *fmt,...)\n\n{\n  asneeded_minfo *paVar1;\n  char *in_stack_00000008;\n  bfd *in_stack_0000000c;\n  char *in_stack_00000010;\n  \n  if (config.map_file != (FILE *)0x0) {\n    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }\n    else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }\n  }\n  return;\n}\n\n" comment comment (function_definition "void minfo(char *fmt,...)\n\n{\n  asneeded_minfo *paVar1;\n  char *in_stack_00000008;\n  bfd *in_stack_0000000c;\n  char *in_stack_00000010;\n  \n  if (config.map_file != (FILE *)0x0) {\n    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }\n    else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }\n  }\n  return;\n}" primitive_type (function_declarator "minfo(char *fmt,...)" identifier (parameter_list "(char *fmt,...)" ( (parameter_declaration "char *fmt" primitive_type (pointer_declarator "*fmt" * identifier)) , (variadic_parameter "..." ...) ))) (compound_statement "{\n  asneeded_minfo *paVar1;\n  char *in_stack_00000008;\n  bfd *in_stack_0000000c;\n  char *in_stack_00000010;\n  \n  if (config.map_file != (FILE *)0x0) {\n    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }\n    else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }\n  }\n  return;\n}" { (declaration "asneeded_minfo *paVar1;" type_identifier (pointer_declarator "*paVar1" * identifier) ;) (declaration "char *in_stack_00000008;" primitive_type (pointer_declarator "*in_stack_00000008" * identifier) ;) (declaration "bfd *in_stack_0000000c;" type_identifier (pointer_declarator "*in_stack_0000000c" * identifier) ;) (declaration "char *in_stack_00000010;" primitive_type (pointer_declarator "*in_stack_00000010" * identifier) ;) (if_statement "if (config.map_file != (FILE *)0x0) {\n    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }\n    else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }\n  }" if (parenthesized_expression "(config.map_file != (FILE *)0x0)" ( (binary_expression "config.map_file != (FILE *)0x0" (field_expression "config.map_file" identifier . field_identifier) != (cast_expression "(FILE *)0x0" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }\n    else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }\n  }" { (if_statement "if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }\n    else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }" if (parenthesized_expression "(((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0'))" ( (binary_expression "((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')" (parenthesized_expression "((*fmt == '%') && (fmt[1] == '!'))" ( (binary_expression "(*fmt == '%') && (fmt[1] == '!')" (parenthesized_expression "(*fmt == '%')" ( (binary_expression "*fmt == '%'" (pointer_expression "*fmt" * identifier) == (char_literal "'%'" ' character ')) )) && (parenthesized_expression "(fmt[1] == '!')" ( (binary_expression "fmt[1] == '!'" (subscript_expression "fmt[1]" identifier [ number_literal ]) == (char_literal "'!'" ' character ')) ))) )) && (parenthesized_expression "(fmt[2] == '\0')" ( (binary_expression "fmt[2] == '\0'" (subscript_expression "fmt[2]" identifier [ number_literal ]) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n      paVar1 = (asneeded_minfo *)xmalloc(0x10);\n      paVar1->next = (asneeded_minfo *)0x0;\n      paVar1->soname = in_stack_00000008;\n      paVar1->ref = in_stack_0000000c;\n      paVar1->name = in_stack_00000010;\n      *asneeded_list_tail = paVar1;\n      asneeded_list_tail = (asneeded_minfo **)paVar1;\n    }" { (expression_statement "paVar1 = (asneeded_minfo *)xmalloc(0x10);" (assignment_expression "paVar1 = (asneeded_minfo *)xmalloc(0x10)" identifier = (cast_expression "(asneeded_minfo *)xmalloc(0x10)" ( (type_descriptor "asneeded_minfo *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(0x10)" identifier (argument_list "(0x10)" ( number_literal ))))) ;) (expression_statement "paVar1->next = (asneeded_minfo *)0x0;" (assignment_expression "paVar1->next = (asneeded_minfo *)0x0" (field_expression "paVar1->next" identifier -> field_identifier) = (cast_expression "(asneeded_minfo *)0x0" ( (type_descriptor "asneeded_minfo *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "paVar1->soname = in_stack_00000008;" (assignment_expression "paVar1->soname = in_stack_00000008" (field_expression "paVar1->soname" identifier -> field_identifier) = identifier) ;) (expression_statement "paVar1->ref = in_stack_0000000c;" (assignment_expression "paVar1->ref = in_stack_0000000c" (field_expression "paVar1->ref" identifier -> field_identifier) = identifier) ;) (expression_statement "paVar1->name = in_stack_00000010;" (assignment_expression "paVar1->name = in_stack_00000010" (field_expression "paVar1->name" identifier -> field_identifier) = identifier) ;) (expression_statement "*asneeded_list_tail = paVar1;" (assignment_expression "*asneeded_list_tail = paVar1" (pointer_expression "*asneeded_list_tail" * identifier) = identifier) ;) (expression_statement "asneeded_list_tail = (asneeded_minfo **)paVar1;" (assignment_expression "asneeded_list_tail = (asneeded_minfo **)paVar1" identifier = (cast_expression "(asneeded_minfo **)paVar1" ( (type_descriptor "asneeded_minfo **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) ;) }) (else_clause "else {\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }" else (compound_statement "{\n      vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);\n    }" { (expression_statement "vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0);" (call_expression "vfinfo(config.map_file,fmt,(va_list)&stack0x00000008,0)" identifier (argument_list "(config.map_file,fmt,(va_list)&stack0x00000008,0)" ( (field_expression "config.map_file" identifier . field_identifier) , identifier , (binary_expression "(va_list)&stack0x00000008" (parenthesized_expression "(va_list)" ( identifier )) & identifier) , number_literal ))) ;) }))) })) (return_statement "return;" return ;) })))
(translation_unit "void FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)\n\n{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}\n\n" (function_definition "void FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)\n\n{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}" primitive_type (function_declarator "FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)" identifier (parameter_list "(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) ))) (compound_statement "{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}" { (declaration "undefined4 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (if_statement "if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }" if (parenthesized_expression "(DAT_0008cd50 != 0)" ( (binary_expression "DAT_0008cd50 != 0" identifier != number_literal) )) (compound_statement "{\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }" { (if_statement "if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" if (parenthesized_expression "(((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0'))" ( (binary_expression "((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')" (parenthesized_expression "((*param_1 == '%') && (param_1[1] == '!'))" ( (binary_expression "(*param_1 == '%') && (param_1[1] == '!')" (parenthesized_expression "(*param_1 == '%')" ( (binary_expression "*param_1 == '%'" (pointer_expression "*param_1" * identifier) == (char_literal "'%'" ' character ')) )) && (parenthesized_expression "(param_1[1] == '!')" ( (binary_expression "param_1[1] == '!'" (subscript_expression "param_1[1]" identifier [ number_literal ]) == (char_literal "'!'" ' character ')) ))) )) && (parenthesized_expression "(param_1[2] == '\0')" ( (binary_expression "param_1[2] == '\0'" (subscript_expression "param_1[2]" identifier [ number_literal ]) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }" { (expression_statement "puVar1 = (undefined4 *)xmalloc(0x10);" (assignment_expression "puVar1 = (undefined4 *)xmalloc(0x10)" identifier = (cast_expression "(undefined4 *)xmalloc(0x10)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(0x10)" identifier (argument_list "(0x10)" ( number_literal ))))) ;) (expression_statement "*puVar1 = 0;" (assignment_expression "*puVar1 = 0" (pointer_expression "*puVar1" * identifier) = number_literal) ;) (expression_statement "puVar1[1] = param_2;" (assignment_expression "puVar1[1] = param_2" (subscript_expression "puVar1[1]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar1[2] = param_3;" (assignment_expression "puVar1[2] = param_3" (subscript_expression "puVar1[2]" identifier [ number_literal ]) = identifier) ;) (expression_statement "puVar1[3] = param_4;" (assignment_expression "puVar1[3] = param_4" (subscript_expression "puVar1[3]" identifier [ number_literal ]) = identifier) ;) (expression_statement "*DAT_0008cba0 = puVar1;" (assignment_expression "*DAT_0008cba0 = puVar1" (pointer_expression "*DAT_0008cba0" * identifier) = identifier) ;) (expression_statement "DAT_0008cba0 = puVar1;" (assignment_expression "DAT_0008cba0 = puVar1" identifier = identifier) ;) }) (else_clause "else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" else (compound_statement "{\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" { (expression_statement "FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);" (call_expression "FUN_000308a0(DAT_0008cd50,param_1,&param_2,0)" identifier (argument_list "(DAT_0008cd50,param_1,&param_2,0)" ( identifier , identifier , (pointer_expression "&param_2" & identifier) , number_literal ))) ;) }))) })) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == (char_literal ' character ')) )) && (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == (char_literal ' character ')) ))) )) && (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == (char_literal ' escape_sequence ')) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( LIT ))))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , (pointer_expression & IDENT) , LIT ))) ;) }))) })) (return_statement return ;) })))
(function_definition "void FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)\n\n{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}" (primitive_type "void") (function_declarator "FUN_00031790(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)" (identifier "FUN_00031790") (parameter_list "(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)" (( "(") (parameter_declaration "char *param_1" (primitive_type "char") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "undefined4 param_2" (type_identifier "undefined4") (identifier "param_2")) (, ",") (parameter_declaration "undefined4 param_3" (type_identifier "undefined4") (identifier "param_3")) (, ",") (parameter_declaration "undefined4 param_4" (type_identifier "undefined4") (identifier "param_4")) () ")"))) (compound_statement "{\n  undefined4 *puVar1;\n  \n  if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }\n  return;\n}" ({ "{") (declaration "undefined4 *puVar1;" (type_identifier "undefined4") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (if_statement "if (DAT_0008cd50 != 0) {\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }" (if "if") (parenthesized_expression "(DAT_0008cd50 != 0)" (( "(") (binary_expression "DAT_0008cd50 != 0" (identifier "DAT_0008cd50") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }\n  }" ({ "{") (if_statement "if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }\n    else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" (if "if") (parenthesized_expression "(((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0'))" (( "(") (binary_expression "((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')" (parenthesized_expression "((*param_1 == '%') && (param_1[1] == '!'))" (( "(") (binary_expression "(*param_1 == '%') && (param_1[1] == '!')" (parenthesized_expression "(*param_1 == '%')" (( "(") (binary_expression "*param_1 == '%'" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (== "==") (char_literal "'%'" (' "'") (character "%") (' "'"))) () ")")) (&& "&&") (parenthesized_expression "(param_1[1] == '!')" (( "(") (binary_expression "param_1[1] == '!'" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (== "==") (char_literal "'!'" (' "'") (character "!") (' "'"))) () ")"))) () ")")) (&& "&&") (parenthesized_expression "(param_1[2] == '\0')" (( "(") (binary_expression "param_1[2] == '\0'" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")"))) () ")")) (compound_statement "{\n      puVar1 = (undefined4 *)xmalloc(0x10);\n      *puVar1 = 0;\n      puVar1[1] = param_2;\n      puVar1[2] = param_3;\n      puVar1[3] = param_4;\n      *DAT_0008cba0 = puVar1;\n      DAT_0008cba0 = puVar1;\n    }" ({ "{") (expression_statement "puVar1 = (undefined4 *)xmalloc(0x10);" (assignment_expression "puVar1 = (undefined4 *)xmalloc(0x10)" (identifier "puVar1") (= "=") (cast_expression "(undefined4 *)xmalloc(0x10)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "xmalloc(0x10)" (identifier "xmalloc") (argument_list "(0x10)" (( "(") (number_literal "0x10") () ")"))))) (; ";")) (expression_statement "*puVar1 = 0;" (assignment_expression "*puVar1 = 0" (pointer_expression "*puVar1" (* "*") (identifier "puVar1")) (= "=") (number_literal "0")) (; ";")) (expression_statement "puVar1[1] = param_2;" (assignment_expression "puVar1[1] = param_2" (subscript_expression "puVar1[1]" (identifier "puVar1") ([ "[") (number_literal "1") (] "]")) (= "=") (identifier "param_2")) (; ";")) (expression_statement "puVar1[2] = param_3;" (assignment_expression "puVar1[2] = param_3" (subscript_expression "puVar1[2]" (identifier "puVar1") ([ "[") (number_literal "2") (] "]")) (= "=") (identifier "param_3")) (; ";")) (expression_statement "puVar1[3] = param_4;" (assignment_expression "puVar1[3] = param_4" (subscript_expression "puVar1[3]" (identifier "puVar1") ([ "[") (number_literal "3") (] "]")) (= "=") (identifier "param_4")) (; ";")) (expression_statement "*DAT_0008cba0 = puVar1;" (assignment_expression "*DAT_0008cba0 = puVar1" (pointer_expression "*DAT_0008cba0" (* "*") (identifier "DAT_0008cba0")) (= "=") (identifier "puVar1")) (; ";")) (expression_statement "DAT_0008cba0 = puVar1;" (assignment_expression "DAT_0008cba0 = puVar1" (identifier "DAT_0008cba0") (= "=") (identifier "puVar1")) (; ";")) (} "}")) (else_clause "else {\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" (else "else") (compound_statement "{\n      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);\n    }" ({ "{") (expression_statement "FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);" (call_expression "FUN_000308a0(DAT_0008cd50,param_1,&param_2,0)" (identifier "FUN_000308a0") (argument_list "(DAT_0008cd50,param_1,&param_2,0)" (( "(") (identifier "DAT_0008cd50") (, ",") (identifier "param_1") (, ",") (pointer_expression "&param_2" (& "&") (identifier "param_2")) (, ",") (number_literal "0") () ")"))) (; ";")) (} "}")))) (} "}"))) (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 *fmt,...)

{
  type_1 *paVar1;
  char *in_stack_00000008;
  type_2 *in_stack_0000000c;
  char *in_stack_00000010;
  
  if (config.map_file != (type_3 *)0x0) {
    if (((*fmt == '%') && (fmt[1] == '!')) && (fmt[2] == '\0')) {
      paVar1 = (type_1 *)var_1(0x10);
      paVar1->next = (type_1 *)0x0;
      paVar1->soname = in_stack_00000008;
      paVar1->ref = in_stack_0000000c;
      paVar1->name = in_stack_00000010;
      *asneeded_list_tail = paVar1;
      asneeded_list_tail = (type_1 **)paVar1;
    }
    else {
      var_2(config.map_file,fmt,(va_list)&var_3,0);
    }
  }
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (character)))) right: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (char_literal (character)))))) right: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (char_literal (escape_sequence)))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (number_literal)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) alternative: (else_clause (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (pointer_expression argument: (identifier)) (number_literal))))))))) (return_statement))))

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

void MASKED(char *param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4)

{
  undefined4 *puVar1;
  
  if (DAT_0008cd50 != 0) {
    if (((*param_1 == '%') && (param_1[1] == '!')) && (param_1[2] == '\0')) {
      puVar1 = (undefined4 *)xmalloc(0x10);
      *puVar1 = 0;
      puVar1[1] = param_2;
      puVar1[2] = param_3;
      puVar1[3] = param_4;
      *DAT_0008cba0 = puVar1;
      DAT_0008cba0 = puVar1;
    }
    else {
      FUN_000308a0(DAT_0008cd50,param_1,&param_2,0);
    }
  }
  return;
}

