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

bfd_boolean cref_fill_array(cref_hash_entry *h,void *data)

{
  undefined4 *puVar1;
  char *pcVar2;
  
  if (h->demangled != (char *)0x0) {
    info_assert("../../ld/ldcref.c",0x14b);
  }
  pcVar2 = (char *)bfd_demangle(link_info.output_bfd,(h->root).string,3);
  h->demangled = pcVar2;
  if (pcVar2 == (char *)0x0) {
    h->demangled = (h->root).string;
  }
                    /* WARNING: Load size is inaccurate */
  puVar1 = *data;
  *puVar1 = h;
  *(undefined4 **)data = puVar1 + 1;
  return 1;
}



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

undefined4 FUN_00035e90(int param_1,int *param_2)

{
  int *piVar1;
  int iVar2;
  
  if (*(int *)(param_1 + 0xc) != 0) {
    FUN_00034e10("../../ld/ldcref.c",0x14b);
  }
  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);
  *(int *)(param_1 + 0xc) = iVar2;
  if (iVar2 == 0) {
    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);
  }
  piVar1 = (int *)*param_2;
  *piVar1 = param_1;
  *param_2 = (int)(piVar1 + 1);
  return 1;
}


PUSH EDI
PUSH ESI
PUSH EBX
MOV ESI,dword ptr [ESP + 0x10]
CALL 0x00017c50
ADD EBX,0x18c164
MOV EDI,dword ptr [ESP + 0x14]
MOV EAX,dword ptr [ESI + 0xc]
TEST EAX,EAX
JZ 0x00035ec4
SUB ESP,0x8
LEA EAX,[EBX + 0xffebfd15]
PUSH 0x14b
PUSH EAX
CALL 0x00034e10
ADD ESP,0x10
LEA EAX,[EBX + 0x25e0]
SUB ESP,0x4
PUSH 0x3
PUSH dword ptr [ESI + 0x4]
PUSH dword ptr [EAX + 0x34]
CALL 0x00016a90
ADD ESP,0x10
MOV dword ptr [ESI + 0xc],EAX
TEST EAX,EAX
JZ 0x00035f00
MOV EAX,dword ptr [EDI]
MOV dword ptr [EAX],ESI
ADD EAX,0x4
MOV dword ptr [EDI],EAX
MOV EAX,0x1
POP EBX
POP ESI
POP EDI
RET
MOV EAX,dword ptr [ESI + 0x4]
MOV dword ptr [ESI + 0xc],EAX
JMP 0x00035ee4
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 FUN_00035e90(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}\n\n" comment (function_definition "undefined4 FUN_00035e90(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}" type_identifier (function_declarator "FUN_00035e90(int param_1,int *param_2)" identifier (parameter_list "(int param_1,int *param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (if_statement "if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0xc) != 0)" ( (binary_expression "*(int *)(param_1 + 0xc) != 0" (pointer_expression "*(int *)(param_1 + 0xc)" * (cast_expression "(int *)(param_1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }" { (expression_statement "FUN_00034e10("../../ld/ldcref.c",0x14b);" (call_expression "FUN_00034e10("../../ld/ldcref.c",0x14b)" identifier (argument_list "("../../ld/ldcref.c",0x14b)" ( (string_literal ""../../ld/ldcref.c"" " string_content ") , number_literal ))) ;) })) (expression_statement "iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);" (assignment_expression "iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" identifier = (call_expression "bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" identifier (argument_list "(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" ( identifier , (pointer_expression "*(undefined4 *)(param_1 + 4)" * (cast_expression "(undefined4 *)(param_1 + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) , number_literal )))) ;) (expression_statement "*(int *)(param_1 + 0xc) = iVar2;" (assignment_expression "*(int *)(param_1 + 0xc) = iVar2" (pointer_expression "*(int *)(param_1 + 0xc)" * (cast_expression "(int *)(param_1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = identifier) ;) (if_statement "if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }" { (expression_statement "*(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);" (assignment_expression "*(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4)" (pointer_expression "*(undefined4 *)(param_1 + 0xc)" * (cast_expression "(undefined4 *)(param_1 + 0xc)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = (pointer_expression "*(undefined4 *)(param_1 + 4)" * (cast_expression "(undefined4 *)(param_1 + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) })) (expression_statement "piVar1 = (int *)*param_2;" (assignment_expression "piVar1 = (int *)*param_2" identifier = (cast_expression "(int *)*param_2" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) ;) (expression_statement "*piVar1 = param_1;" (assignment_expression "*piVar1 = param_1" (pointer_expression "*piVar1" * identifier) = identifier) ;) (expression_statement "*param_2 = (int)(piVar1 + 1);" (assignment_expression "*param_2 = (int)(piVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(piVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(piVar1 + 1)" ( (binary_expression "piVar1 + 1" identifier + number_literal) )))) ;) (return_statement "return 1;" return number_literal ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nbfd_boolean cref_fill_array(cref_hash_entry *h,void *data)\n\n{\n  undefined4 *puVar1;\n  char *pcVar2;\n  \n  if (h->demangled != (char *)0x0) {\n    info_assert("../../ld/ldcref.c",0x14b);\n  }\n  pcVar2 = (char *)bfd_demangle(link_info.output_bfd,(h->root).string,3);\n  h->demangled = pcVar2;\n  if (pcVar2 == (char *)0x0) {\n    h->demangled = (h->root).string;\n  }\n                    /* WARNING: Load size is inaccurate */\n  puVar1 = *data;\n  *puVar1 = h;\n  *(undefined4 **)data = puVar1 + 1;\n  return 1;\n}\n\n" comment comment (function_definition "bfd_boolean cref_fill_array(cref_hash_entry *h,void *data)\n\n{\n  undefined4 *puVar1;\n  char *pcVar2;\n  \n  if (h->demangled != (char *)0x0) {\n    info_assert("../../ld/ldcref.c",0x14b);\n  }\n  pcVar2 = (char *)bfd_demangle(link_info.output_bfd,(h->root).string,3);\n  h->demangled = pcVar2;\n  if (pcVar2 == (char *)0x0) {\n    h->demangled = (h->root).string;\n  }\n                    /* WARNING: Load size is inaccurate */\n  puVar1 = *data;\n  *puVar1 = h;\n  *(undefined4 **)data = puVar1 + 1;\n  return 1;\n}" type_identifier (function_declarator "cref_fill_array(cref_hash_entry *h,void *data)" identifier (parameter_list "(cref_hash_entry *h,void *data)" ( (parameter_declaration "cref_hash_entry *h" type_identifier (pointer_declarator "*h" * identifier)) , (parameter_declaration "void *data" primitive_type (pointer_declarator "*data" * identifier)) ))) (compound_statement "{\n  undefined4 *puVar1;\n  char *pcVar2;\n  \n  if (h->demangled != (char *)0x0) {\n    info_assert("../../ld/ldcref.c",0x14b);\n  }\n  pcVar2 = (char *)bfd_demangle(link_info.output_bfd,(h->root).string,3);\n  h->demangled = pcVar2;\n  if (pcVar2 == (char *)0x0) {\n    h->demangled = (h->root).string;\n  }\n                    /* WARNING: Load size is inaccurate */\n  puVar1 = *data;\n  *puVar1 = h;\n  *(undefined4 **)data = puVar1 + 1;\n  return 1;\n}" { (declaration "undefined4 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if (h->demangled != (char *)0x0) {\n    info_assert("../../ld/ldcref.c",0x14b);\n  }" if (parenthesized_expression "(h->demangled != (char *)0x0)" ( (binary_expression "h->demangled != (char *)0x0" (field_expression "h->demangled" identifier -> field_identifier) != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    info_assert("../../ld/ldcref.c",0x14b);\n  }" { (expression_statement "info_assert("../../ld/ldcref.c",0x14b);" (call_expression "info_assert("../../ld/ldcref.c",0x14b)" identifier (argument_list "("../../ld/ldcref.c",0x14b)" ( (string_literal ""../../ld/ldcref.c"" " string_content ") , number_literal ))) ;) })) (expression_statement "pcVar2 = (char *)bfd_demangle(link_info.output_bfd,(h->root).string,3);" (assignment_expression "pcVar2 = (char *)bfd_demangle(link_info.output_bfd,(h->root).string,3)" identifier = (cast_expression "(char *)bfd_demangle(link_info.output_bfd,(h->root).string,3)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "bfd_demangle(link_info.output_bfd,(h->root).string,3)" identifier (argument_list "(link_info.output_bfd,(h->root).string,3)" ( (field_expression "link_info.output_bfd" identifier . field_identifier) , (field_expression "(h->root).string" (parenthesized_expression "(h->root)" ( (field_expression "h->root" identifier -> field_identifier) )) . field_identifier) , number_literal ))))) ;) (expression_statement "h->demangled = pcVar2;" (assignment_expression "h->demangled = pcVar2" (field_expression "h->demangled" identifier -> field_identifier) = identifier) ;) (if_statement "if (pcVar2 == (char *)0x0) {\n    h->demangled = (h->root).string;\n  }" if (parenthesized_expression "(pcVar2 == (char *)0x0)" ( (binary_expression "pcVar2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    h->demangled = (h->root).string;\n  }" { (expression_statement "h->demangled = (h->root).string;" (assignment_expression "h->demangled = (h->root).string" (field_expression "h->demangled" identifier -> field_identifier) = (field_expression "(h->root).string" (parenthesized_expression "(h->root)" ( (field_expression "h->root" identifier -> field_identifier) )) . field_identifier)) ;) })) comment (expression_statement "puVar1 = *data;" (assignment_expression "puVar1 = *data" identifier = (pointer_expression "*data" * identifier)) ;) (expression_statement "*puVar1 = h;" (assignment_expression "*puVar1 = h" (pointer_expression "*puVar1" * identifier) = identifier) ;) (expression_statement "*(undefined4 **)data = puVar1 + 1;" (assignment_expression "*(undefined4 **)data = puVar1 + 1" (pointer_expression "*(undefined4 **)data" * (cast_expression "(undefined4 **)data" ( (type_descriptor "undefined4 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "puVar1 + 1" identifier + number_literal)) ;) (return_statement "return 1;" return number_literal ;) })))
(translation_unit "undefined4 FUN_00035e90(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}\n\n" (function_definition "undefined4 FUN_00035e90(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}" type_identifier (function_declarator "FUN_00035e90(int param_1,int *param_2)" identifier (parameter_list "(int param_1,int *param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (if_statement "if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0xc) != 0)" ( (binary_expression "*(int *)(param_1 + 0xc) != 0" (pointer_expression "*(int *)(param_1 + 0xc)" * (cast_expression "(int *)(param_1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }" { (expression_statement "FUN_00034e10("../../ld/ldcref.c",0x14b);" (call_expression "FUN_00034e10("../../ld/ldcref.c",0x14b)" identifier (argument_list "("../../ld/ldcref.c",0x14b)" ( (string_literal ""../../ld/ldcref.c"" " string_content ") , number_literal ))) ;) })) (expression_statement "iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);" (assignment_expression "iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" identifier = (call_expression "bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" identifier (argument_list "(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" ( identifier , (pointer_expression "*(undefined4 *)(param_1 + 4)" * (cast_expression "(undefined4 *)(param_1 + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) , number_literal )))) ;) (expression_statement "*(int *)(param_1 + 0xc) = iVar2;" (assignment_expression "*(int *)(param_1 + 0xc) = iVar2" (pointer_expression "*(int *)(param_1 + 0xc)" * (cast_expression "(int *)(param_1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = identifier) ;) (if_statement "if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }" { (expression_statement "*(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);" (assignment_expression "*(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4)" (pointer_expression "*(undefined4 *)(param_1 + 0xc)" * (cast_expression "(undefined4 *)(param_1 + 0xc)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) = (pointer_expression "*(undefined4 *)(param_1 + 4)" * (cast_expression "(undefined4 *)(param_1 + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) })) (expression_statement "piVar1 = (int *)*param_2;" (assignment_expression "piVar1 = (int *)*param_2" identifier = (cast_expression "(int *)*param_2" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) ;) (expression_statement "*piVar1 = param_1;" (assignment_expression "*piVar1 = param_1" (pointer_expression "*piVar1" * identifier) = identifier) ;) (expression_statement "*param_2 = (int)(piVar1 + 1);" (assignment_expression "*param_2 = (int)(piVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(piVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(piVar1 + 1)" ( (binary_expression "piVar1 + 1" identifier + number_literal) )))) ;) (return_statement "return 1;" return number_literal ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (string_literal " string_content ") , LIT ))) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT )))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (return_statement return LIT ;) })))
(function_definition "undefined4 FUN_00035e90(int param_1,int *param_2)\n\n{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}" (type_identifier "undefined4") (function_declarator "FUN_00035e90(int param_1,int *param_2)" (identifier "FUN_00035e90") (parameter_list "(int param_1,int *param_2)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int *param_2" (primitive_type "int") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")"))) (compound_statement "{\n  int *piVar1;\n  int iVar2;\n  \n  if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }\n  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);\n  *(int *)(param_1 + 0xc) = iVar2;\n  if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }\n  piVar1 = (int *)*param_2;\n  *piVar1 = param_1;\n  *param_2 = (int)(piVar1 + 1);\n  return 1;\n}" ({ "{") (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (if_statement "if (*(int *)(param_1 + 0xc) != 0) {\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0xc) != 0)" (( "(") (binary_expression "*(int *)(param_1 + 0xc) != 0" (pointer_expression "*(int *)(param_1 + 0xc)" (* "*") (cast_expression "(int *)(param_1 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    FUN_00034e10("../../ld/ldcref.c",0x14b);\n  }" ({ "{") (expression_statement "FUN_00034e10("../../ld/ldcref.c",0x14b);" (call_expression "FUN_00034e10("../../ld/ldcref.c",0x14b)" (identifier "FUN_00034e10") (argument_list "("../../ld/ldcref.c",0x14b)" (( "(") (string_literal ""../../ld/ldcref.c"" (" """) (string_content "../../ld/ldcref.c") (" """)) (, ",") (number_literal "0x14b") () ")"))) (; ";")) (} "}"))) (expression_statement "iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);" (assignment_expression "iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" (identifier "iVar2") (= "=") (call_expression "bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" (identifier "bfd_demangle") (argument_list "(DAT_001c4614,*(undefined4 *)(param_1 + 4),3)" (( "(") (identifier "DAT_001c4614") (, ",") (pointer_expression "*(undefined4 *)(param_1 + 4)" (* "*") (cast_expression "(undefined4 *)(param_1 + 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")")))) (, ",") (number_literal "3") () ")")))) (; ";")) (expression_statement "*(int *)(param_1 + 0xc) = iVar2;" (assignment_expression "*(int *)(param_1 + 0xc) = iVar2" (pointer_expression "*(int *)(param_1 + 0xc)" (* "*") (cast_expression "(int *)(param_1 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (= "=") (identifier "iVar2")) (; ";")) (if_statement "if (iVar2 == 0) {\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);\n  }" ({ "{") (expression_statement "*(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);" (assignment_expression "*(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4)" (pointer_expression "*(undefined4 *)(param_1 + 0xc)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0xc)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (= "=") (pointer_expression "*(undefined4 *)(param_1 + 4)" (* "*") (cast_expression "(undefined4 *)(param_1 + 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (} "}"))) (expression_statement "piVar1 = (int *)*param_2;" (assignment_expression "piVar1 = (int *)*param_2" (identifier "piVar1") (= "=") (cast_expression "(int *)*param_2" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_2" (* "*") (identifier "param_2")))) (; ";")) (expression_statement "*piVar1 = param_1;" (assignment_expression "*piVar1 = param_1" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (= "=") (identifier "param_1")) (; ";")) (expression_statement "*param_2 = (int)(piVar1 + 1);" (assignment_expression "*param_2 = (int)(piVar1 + 1)" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (cast_expression "(int)(piVar1 + 1)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(piVar1 + 1)" (( "(") (binary_expression "piVar1 + 1" (identifier "piVar1") (+ "+") (number_literal "1")) () ")")))) (; ";")) (return_statement "return 1;" (return "return") (number_literal "1") (; ";")) (} "}")))

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

type_1 function_1(type_2 *h,void *data)

{
  type_3 *var_4;
  char *var_3;
  
  if (h->demangled != (char *)0x0) {
    var_1("../../ld/ldcref.c",0x14b);
  }
  var_3 = (char *)var_2(link_info.output_bfd,(h->root).string,3);
  h->demangled = var_3;
  if (var_3 == (char *)0x0) {
    h->demangled = (h->root).string;
  }
                    /* WARNING: Load size is inaccurate */
  var_4 = *data;
  *var_4 = h;
  *(type_3 **)data = var_4 + 1;
  return 1;
}


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

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

undefined4 MASKED(int param_1,int *param_2)

{
  int *piVar1;
  int iVar2;
  
  if (*(int *)(param_1 + 0xc) != 0) {
    FUN_00034e10("../../ld/ldcref.c",0x14b);
  }
  iVar2 = bfd_demangle(DAT_001c4614,*(undefined4 *)(param_1 + 4),3);
  *(int *)(param_1 + 0xc) = iVar2;
  if (iVar2 == 0) {
    *(undefined4 *)(param_1 + 0xc) = *(undefined4 *)(param_1 + 4);
  }
  piVar1 = (int *)*param_2;
  *piVar1 = param_1;
  *param_2 = (int)(piVar1 + 1);
  return 1;
}

