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

void d_growable_string_callback_adapter(char *s,size_t l,void *opaque)

{
}



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

void FUN_002362e0(void *param_1,size_t param_2,int *param_3)

{
  uint uVar1;
  void *pvVar2;
  int iVar3;
  uint __size;
  
  __size = param_3[2];
  iVar3 = param_3[3];
  uVar1 = param_2 + 1 + param_3[1];
  if (__size < uVar1) {
    if (iVar3 != 0) {
      return;
    }
    if ((__size != 0) || (__size = 2, 2 < uVar1)) {
      do {
        __size = __size * 2;
      } while (__size < uVar1);
    }
    pvVar2 = realloc((void *)*param_3,__size);
    if (pvVar2 == (void *)0x0) {
      free((void *)*param_3);
      *param_3 = 0;
      param_3[1] = 0;
      param_3[2] = 0;
      param_3[3] = 1;
      return;
    }
    *param_3 = (int)pvVar2;
    iVar3 = param_3[3];
    param_3[2] = __size;
  }
  if (iVar3 == 0) {
    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);
    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;
    param_3[1] = param_3[1] + param_2;
  }
  return;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x0003a210
ADD EBX,0x1ddd17
SUB ESP,0xc
MOV ESI,dword ptr [ESP + 0x28]
MOV EBP,dword ptr [ESP + 0x24]
MOV EAX,dword ptr [ESI + 0x4]
MOV EDI,dword ptr [ESI + 0x8]
MOV EDX,dword ptr [ESI + 0xc]
LEA EAX,[EBP + EAX*0x1 + 0x1]
CMP EAX,EDI
JA 0x00236340
TEST EDX,EDX
JNZ 0x00236332
MOV EAX,dword ptr [ESI + 0x4]
SUB ESP,0x4
ADD EAX,dword ptr [ESI]
PUSH EBP
PUSH dword ptr [ESP + 0x28]
PUSH EAX
CALL 0x0002c2d0
MOV EAX,dword ptr [ESI]
ADD ESP,0x10
ADD EAX,EBP
ADD EAX,dword ptr [ESI + 0x4]
MOV byte ptr [EAX],0x0
ADD dword ptr [ESI + 0x4],EBP
ADD ESP,0xc
POP EBX
POP ESI
POP EDI
POP EBP
RET
TEST EDX,EDX
JNZ 0x00236332
TEST EDI,EDI
JZ 0x00236378
LEA ESI,[ESI]
NOP
ADD EDI,EDI
CMP EAX,EDI
JA 0x00236350
SUB ESP,0x8
PUSH EDI
PUSH dword ptr [ESI]
CALL 0x0002cb10
ADD ESP,0x10
TEST EAX,EAX
JZ 0x00236388
MOV dword ptr [ESI],EAX
MOV EDX,dword ptr [ESI + 0xc]
MOV dword ptr [ESI + 0x8],EDI
JMP 0x0023630b
MOV EDI,0x2
CMP EAX,0x2
JA 0x00236350
JMP 0x00236356
SUB ESP,0xc
PUSH dword ptr [ESI]
CALL 0x0002c700
MOV dword ptr [ESI],0x0
ADD ESP,0x10
MOV dword ptr [ESI + 0x4],0x0
MOV dword ptr [ESI + 0x8],0x0
MOV dword ptr [ESI + 0xc],0x1
JMP 0x00236332
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_002362e0(void *param_1,size_t param_2,int *param_3)\n\n{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}\n\n" comment (function_definition "void FUN_002362e0(void *param_1,size_t param_2,int *param_3)\n\n{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}" primitive_type (function_declarator "FUN_002362e0(void *param_1,size_t param_2,int *param_3)" identifier (parameter_list "(void *param_1,size_t param_2,int *param_3)" ( (parameter_declaration "void *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "size_t param_2" primitive_type identifier) , (parameter_declaration "int *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "void *pvVar2;" primitive_type (pointer_declarator "*pvVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "uint __size;" type_identifier identifier ;) (expression_statement "__size = param_3[2];" (assignment_expression "__size = param_3[2]" identifier = (subscript_expression "param_3[2]" identifier [ number_literal ])) ;) (expression_statement "iVar3 = param_3[3];" (assignment_expression "iVar3 = param_3[3]" identifier = (subscript_expression "param_3[3]" identifier [ number_literal ])) ;) (expression_statement "uVar1 = param_2 + 1 + param_3[1];" (assignment_expression "uVar1 = param_2 + 1 + param_3[1]" identifier = (binary_expression "param_2 + 1 + param_3[1]" (binary_expression "param_2 + 1" identifier + number_literal) + (subscript_expression "param_3[1]" identifier [ number_literal ]))) ;) (if_statement "if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }" if (parenthesized_expression "(__size < uVar1)" ( (binary_expression "__size < uVar1" identifier < identifier) )) (compound_statement "{\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }" { (if_statement "if (iVar3 != 0) {\n      return;\n    }" if (parenthesized_expression "(iVar3 != 0)" ( (binary_expression "iVar3 != 0" identifier != number_literal) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) (if_statement "if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }" if (parenthesized_expression "((__size != 0) || (__size = 2, 2 < uVar1))" ( (binary_expression "(__size != 0) || (__size = 2, 2 < uVar1)" (parenthesized_expression "(__size != 0)" ( (binary_expression "__size != 0" identifier != number_literal) )) || (parenthesized_expression "(__size = 2, 2 < uVar1)" ( (comma_expression "__size = 2, 2 < uVar1" (assignment_expression "__size = 2" identifier = number_literal) , (binary_expression "2 < uVar1" number_literal < identifier)) ))) )) (compound_statement "{\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }" { (do_statement "do {\n        __size = __size * 2;\n      } while (__size < uVar1);" do (compound_statement "{\n        __size = __size * 2;\n      }" { (expression_statement "__size = __size * 2;" (assignment_expression "__size = __size * 2" identifier = (binary_expression "__size * 2" identifier * number_literal)) ;) }) while (parenthesized_expression "(__size < uVar1)" ( (binary_expression "__size < uVar1" identifier < identifier) )) ;) })) (expression_statement "pvVar2 = realloc((void *)*param_3,__size);" (assignment_expression "pvVar2 = realloc((void *)*param_3,__size)" identifier = (call_expression "realloc((void *)*param_3,__size)" identifier (argument_list "((void *)*param_3,__size)" ( (cast_expression "(void *)*param_3" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_3" * identifier)) , identifier )))) ;) (if_statement "if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }" if (parenthesized_expression "(pvVar2 == (void *)0x0)" ( (binary_expression "pvVar2 == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }" { (expression_statement "free((void *)*param_3);" (call_expression "free((void *)*param_3)" identifier (argument_list "((void *)*param_3)" ( (cast_expression "(void *)*param_3" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_3" * identifier)) ))) ;) (expression_statement "*param_3 = 0;" (assignment_expression "*param_3 = 0" (pointer_expression "*param_3" * identifier) = number_literal) ;) (expression_statement "param_3[1] = 0;" (assignment_expression "param_3[1] = 0" (subscript_expression "param_3[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_3[2] = 0;" (assignment_expression "param_3[2] = 0" (subscript_expression "param_3[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_3[3] = 1;" (assignment_expression "param_3[3] = 1" (subscript_expression "param_3[3]" identifier [ number_literal ]) = number_literal) ;) (return_statement "return;" return ;) })) (expression_statement "*param_3 = (int)pvVar2;" (assignment_expression "*param_3 = (int)pvVar2" (pointer_expression "*param_3" * identifier) = (cast_expression "(int)pvVar2" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "iVar3 = param_3[3];" (assignment_expression "iVar3 = param_3[3]" identifier = (subscript_expression "param_3[3]" identifier [ number_literal ])) ;) (expression_statement "param_3[2] = __size;" (assignment_expression "param_3[2] = __size" (subscript_expression "param_3[2]" identifier [ number_literal ]) = identifier) ;) })) (if_statement "if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }" if (parenthesized_expression "(iVar3 == 0)" ( (binary_expression "iVar3 == 0" identifier == number_literal) )) (compound_statement "{\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }" { (expression_statement "memcpy((void *)(param_3[1] + *param_3),param_1,param_2);" (call_expression "memcpy((void *)(param_3[1] + *param_3),param_1,param_2)" identifier (argument_list "((void *)(param_3[1] + *param_3),param_1,param_2)" ( (cast_expression "(void *)(param_3[1] + *param_3)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3[1] + *param_3)" ( (binary_expression "param_3[1] + *param_3" (subscript_expression "param_3[1]" identifier [ number_literal ]) + (pointer_expression "*param_3" * identifier)) ))) , identifier , identifier ))) ;) (expression_statement "*(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;" (assignment_expression "*(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0" (pointer_expression "*(undefined1 *)(*param_3 + param_2 + param_3[1])" * (cast_expression "(undefined1 *)(*param_3 + param_2 + param_3[1])" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_3 + param_2 + param_3[1])" ( (binary_expression "*param_3 + param_2 + param_3[1]" (binary_expression "*param_3 + param_2" (pointer_expression "*param_3" * identifier) + identifier) + (subscript_expression "param_3[1]" identifier [ number_literal ])) )))) = number_literal) ;) (expression_statement "param_3[1] = param_3[1] + param_2;" (assignment_expression "param_3[1] = param_3[1] + param_2" (subscript_expression "param_3[1]" identifier [ number_literal ]) = (binary_expression "param_3[1] + param_2" (subscript_expression "param_3[1]" identifier [ number_literal ]) + identifier)) ;) })) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nvoid d_growable_string_callback_adapter(char *s,size_t l,void *opaque)\n\n{\n}\n\n" comment comment (function_definition "void d_growable_string_callback_adapter(char *s,size_t l,void *opaque)\n\n{\n}" primitive_type (function_declarator "d_growable_string_callback_adapter(char *s,size_t l,void *opaque)" identifier (parameter_list "(char *s,size_t l,void *opaque)" ( (parameter_declaration "char *s" primitive_type (pointer_declarator "*s" * identifier)) , (parameter_declaration "size_t l" primitive_type identifier) , (parameter_declaration "void *opaque" primitive_type (pointer_declarator "*opaque" * identifier)) ))) (compound_statement "{\n}" { })))
(translation_unit "void FUN_002362e0(void *param_1,size_t param_2,int *param_3)\n\n{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}\n\n" (function_definition "void FUN_002362e0(void *param_1,size_t param_2,int *param_3)\n\n{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}" primitive_type (function_declarator "FUN_002362e0(void *param_1,size_t param_2,int *param_3)" identifier (parameter_list "(void *param_1,size_t param_2,int *param_3)" ( (parameter_declaration "void *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "size_t param_2" primitive_type identifier) , (parameter_declaration "int *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "void *pvVar2;" primitive_type (pointer_declarator "*pvVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "uint __size;" type_identifier identifier ;) (expression_statement "__size = param_3[2];" (assignment_expression "__size = param_3[2]" identifier = (subscript_expression "param_3[2]" identifier [ number_literal ])) ;) (expression_statement "iVar3 = param_3[3];" (assignment_expression "iVar3 = param_3[3]" identifier = (subscript_expression "param_3[3]" identifier [ number_literal ])) ;) (expression_statement "uVar1 = param_2 + 1 + param_3[1];" (assignment_expression "uVar1 = param_2 + 1 + param_3[1]" identifier = (binary_expression "param_2 + 1 + param_3[1]" (binary_expression "param_2 + 1" identifier + number_literal) + (subscript_expression "param_3[1]" identifier [ number_literal ]))) ;) (if_statement "if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }" if (parenthesized_expression "(__size < uVar1)" ( (binary_expression "__size < uVar1" identifier < identifier) )) (compound_statement "{\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }" { (if_statement "if (iVar3 != 0) {\n      return;\n    }" if (parenthesized_expression "(iVar3 != 0)" ( (binary_expression "iVar3 != 0" identifier != number_literal) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) (if_statement "if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }" if (parenthesized_expression "((__size != 0) || (__size = 2, 2 < uVar1))" ( (binary_expression "(__size != 0) || (__size = 2, 2 < uVar1)" (parenthesized_expression "(__size != 0)" ( (binary_expression "__size != 0" identifier != number_literal) )) || (parenthesized_expression "(__size = 2, 2 < uVar1)" ( (comma_expression "__size = 2, 2 < uVar1" (assignment_expression "__size = 2" identifier = number_literal) , (binary_expression "2 < uVar1" number_literal < identifier)) ))) )) (compound_statement "{\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }" { (do_statement "do {\n        __size = __size * 2;\n      } while (__size < uVar1);" do (compound_statement "{\n        __size = __size * 2;\n      }" { (expression_statement "__size = __size * 2;" (assignment_expression "__size = __size * 2" identifier = (binary_expression "__size * 2" identifier * number_literal)) ;) }) while (parenthesized_expression "(__size < uVar1)" ( (binary_expression "__size < uVar1" identifier < identifier) )) ;) })) (expression_statement "pvVar2 = realloc((void *)*param_3,__size);" (assignment_expression "pvVar2 = realloc((void *)*param_3,__size)" identifier = (call_expression "realloc((void *)*param_3,__size)" identifier (argument_list "((void *)*param_3,__size)" ( (cast_expression "(void *)*param_3" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_3" * identifier)) , identifier )))) ;) (if_statement "if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }" if (parenthesized_expression "(pvVar2 == (void *)0x0)" ( (binary_expression "pvVar2 == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }" { (expression_statement "free((void *)*param_3);" (call_expression "free((void *)*param_3)" identifier (argument_list "((void *)*param_3)" ( (cast_expression "(void *)*param_3" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_3" * identifier)) ))) ;) (expression_statement "*param_3 = 0;" (assignment_expression "*param_3 = 0" (pointer_expression "*param_3" * identifier) = number_literal) ;) (expression_statement "param_3[1] = 0;" (assignment_expression "param_3[1] = 0" (subscript_expression "param_3[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_3[2] = 0;" (assignment_expression "param_3[2] = 0" (subscript_expression "param_3[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_3[3] = 1;" (assignment_expression "param_3[3] = 1" (subscript_expression "param_3[3]" identifier [ number_literal ]) = number_literal) ;) (return_statement "return;" return ;) })) (expression_statement "*param_3 = (int)pvVar2;" (assignment_expression "*param_3 = (int)pvVar2" (pointer_expression "*param_3" * identifier) = (cast_expression "(int)pvVar2" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "iVar3 = param_3[3];" (assignment_expression "iVar3 = param_3[3]" identifier = (subscript_expression "param_3[3]" identifier [ number_literal ])) ;) (expression_statement "param_3[2] = __size;" (assignment_expression "param_3[2] = __size" (subscript_expression "param_3[2]" identifier [ number_literal ]) = identifier) ;) })) (if_statement "if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }" if (parenthesized_expression "(iVar3 == 0)" ( (binary_expression "iVar3 == 0" identifier == number_literal) )) (compound_statement "{\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }" { (expression_statement "memcpy((void *)(param_3[1] + *param_3),param_1,param_2);" (call_expression "memcpy((void *)(param_3[1] + *param_3),param_1,param_2)" identifier (argument_list "((void *)(param_3[1] + *param_3),param_1,param_2)" ( (cast_expression "(void *)(param_3[1] + *param_3)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3[1] + *param_3)" ( (binary_expression "param_3[1] + *param_3" (subscript_expression "param_3[1]" identifier [ number_literal ]) + (pointer_expression "*param_3" * identifier)) ))) , identifier , identifier ))) ;) (expression_statement "*(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;" (assignment_expression "*(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0" (pointer_expression "*(undefined1 *)(*param_3 + param_2 + param_3[1])" * (cast_expression "(undefined1 *)(*param_3 + param_2 + param_3[1])" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_3 + param_2 + param_3[1])" ( (binary_expression "*param_3 + param_2 + param_3[1]" (binary_expression "*param_3 + param_2" (pointer_expression "*param_3" * identifier) + identifier) + (subscript_expression "param_3[1]" identifier [ number_literal ])) )))) = number_literal) ;) (expression_statement "param_3[1] = param_3[1] + param_2;" (assignment_expression "param_3[1] = param_3[1] + param_2" (subscript_expression "param_3[1]" identifier [ number_literal ]) = (binary_expression "param_3[1] + param_2" (subscript_expression "param_3[1]" identifier [ number_literal ]) + identifier)) ;) })) (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 (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression IDENT = (binary_expression (binary_expression IDENT + LIT) + (subscript_expression IDENT [ LIT ]))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < IDENT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (return_statement return ;) })) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = LIT) , (binary_expression LIT < IDENT)) ))) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT * LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < IDENT) )) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT)) , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT)) ))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (return_statement return ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + (pointer_expression * IDENT)) ))) , IDENT , IDENT ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (pointer_expression * IDENT) + IDENT) + (subscript_expression IDENT [ LIT ])) )))) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression (subscript_expression IDENT [ LIT ]) + IDENT)) ;) })) (return_statement return ;) })))
(function_definition "void FUN_002362e0(void *param_1,size_t param_2,int *param_3)\n\n{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}" (primitive_type "void") (function_declarator "FUN_002362e0(void *param_1,size_t param_2,int *param_3)" (identifier "FUN_002362e0") (parameter_list "(void *param_1,size_t param_2,int *param_3)" (( "(") (parameter_declaration "void *param_1" (primitive_type "void") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "size_t param_2" (primitive_type "size_t") (identifier "param_2")) (, ",") (parameter_declaration "int *param_3" (primitive_type "int") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) () ")"))) (compound_statement "{\n  uint uVar1;\n  void *pvVar2;\n  int iVar3;\n  uint __size;\n  \n  __size = param_3[2];\n  iVar3 = param_3[3];\n  uVar1 = param_2 + 1 + param_3[1];\n  if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }\n  if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }\n  return;\n}" ({ "{") (declaration "uint uVar1;" (type_identifier "uint") (identifier "uVar1") (; ";")) (declaration "void *pvVar2;" (primitive_type "void") (pointer_declarator "*pvVar2" (* "*") (identifier "pvVar2")) (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "uint __size;" (type_identifier "uint") (identifier "__size") (; ";")) (expression_statement "__size = param_3[2];" (assignment_expression "__size = param_3[2]" (identifier "__size") (= "=") (subscript_expression "param_3[2]" (identifier "param_3") ([ "[") (number_literal "2") (] "]"))) (; ";")) (expression_statement "iVar3 = param_3[3];" (assignment_expression "iVar3 = param_3[3]" (identifier "iVar3") (= "=") (subscript_expression "param_3[3]" (identifier "param_3") ([ "[") (number_literal "3") (] "]"))) (; ";")) (expression_statement "uVar1 = param_2 + 1 + param_3[1];" (assignment_expression "uVar1 = param_2 + 1 + param_3[1]" (identifier "uVar1") (= "=") (binary_expression "param_2 + 1 + param_3[1]" (binary_expression "param_2 + 1" (identifier "param_2") (+ "+") (number_literal "1")) (+ "+") (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]")))) (; ";")) (if_statement "if (__size < uVar1) {\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }" (if "if") (parenthesized_expression "(__size < uVar1)" (( "(") (binary_expression "__size < uVar1" (identifier "__size") (< "<") (identifier "uVar1")) () ")")) (compound_statement "{\n    if (iVar3 != 0) {\n      return;\n    }\n    if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }\n    pvVar2 = realloc((void *)*param_3,__size);\n    if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }\n    *param_3 = (int)pvVar2;\n    iVar3 = param_3[3];\n    param_3[2] = __size;\n  }" ({ "{") (if_statement "if (iVar3 != 0) {\n      return;\n    }" (if "if") (parenthesized_expression "(iVar3 != 0)" (( "(") (binary_expression "iVar3 != 0" (identifier "iVar3") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      return;\n    }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (if_statement "if ((__size != 0) || (__size = 2, 2 < uVar1)) {\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }" (if "if") (parenthesized_expression "((__size != 0) || (__size = 2, 2 < uVar1))" (( "(") (binary_expression "(__size != 0) || (__size = 2, 2 < uVar1)" (parenthesized_expression "(__size != 0)" (( "(") (binary_expression "__size != 0" (identifier "__size") (!= "!=") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "(__size = 2, 2 < uVar1)" (( "(") (comma_expression "__size = 2, 2 < uVar1" (assignment_expression "__size = 2" (identifier "__size") (= "=") (number_literal "2")) (, ",") (binary_expression "2 < uVar1" (number_literal "2") (< "<") (identifier "uVar1"))) () ")"))) () ")")) (compound_statement "{\n      do {\n        __size = __size * 2;\n      } while (__size < uVar1);\n    }" ({ "{") (do_statement "do {\n        __size = __size * 2;\n      } while (__size < uVar1);" (do "do") (compound_statement "{\n        __size = __size * 2;\n      }" ({ "{") (expression_statement "__size = __size * 2;" (assignment_expression "__size = __size * 2" (identifier "__size") (= "=") (binary_expression "__size * 2" (identifier "__size") (* "*") (number_literal "2"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(__size < uVar1)" (( "(") (binary_expression "__size < uVar1" (identifier "__size") (< "<") (identifier "uVar1")) () ")")) (; ";")) (} "}"))) (expression_statement "pvVar2 = realloc((void *)*param_3,__size);" (assignment_expression "pvVar2 = realloc((void *)*param_3,__size)" (identifier "pvVar2") (= "=") (call_expression "realloc((void *)*param_3,__size)" (identifier "realloc") (argument_list "((void *)*param_3,__size)" (( "(") (cast_expression "(void *)*param_3" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_3" (* "*") (identifier "param_3"))) (, ",") (identifier "__size") () ")")))) (; ";")) (if_statement "if (pvVar2 == (void *)0x0) {\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }" (if "if") (parenthesized_expression "(pvVar2 == (void *)0x0)" (( "(") (binary_expression "pvVar2 == (void *)0x0" (identifier "pvVar2") (== "==") (cast_expression "(void *)0x0" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n      free((void *)*param_3);\n      *param_3 = 0;\n      param_3[1] = 0;\n      param_3[2] = 0;\n      param_3[3] = 1;\n      return;\n    }" ({ "{") (expression_statement "free((void *)*param_3);" (call_expression "free((void *)*param_3)" (identifier "free") (argument_list "((void *)*param_3)" (( "(") (cast_expression "(void *)*param_3" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_3" (* "*") (identifier "param_3"))) () ")"))) (; ";")) (expression_statement "*param_3 = 0;" (assignment_expression "*param_3 = 0" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_3[1] = 0;" (assignment_expression "param_3[1] = 0" (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_3[2] = 0;" (assignment_expression "param_3[2] = 0" (subscript_expression "param_3[2]" (identifier "param_3") ([ "[") (number_literal "2") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_3[3] = 1;" (assignment_expression "param_3[3] = 1" (subscript_expression "param_3[3]" (identifier "param_3") ([ "[") (number_literal "3") (] "]")) (= "=") (number_literal "1")) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "*param_3 = (int)pvVar2;" (assignment_expression "*param_3 = (int)pvVar2" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (= "=") (cast_expression "(int)pvVar2" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pvVar2"))) (; ";")) (expression_statement "iVar3 = param_3[3];" (assignment_expression "iVar3 = param_3[3]" (identifier "iVar3") (= "=") (subscript_expression "param_3[3]" (identifier "param_3") ([ "[") (number_literal "3") (] "]"))) (; ";")) (expression_statement "param_3[2] = __size;" (assignment_expression "param_3[2] = __size" (subscript_expression "param_3[2]" (identifier "param_3") ([ "[") (number_literal "2") (] "]")) (= "=") (identifier "__size")) (; ";")) (} "}"))) (if_statement "if (iVar3 == 0) {\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }" (if "if") (parenthesized_expression "(iVar3 == 0)" (( "(") (binary_expression "iVar3 == 0" (identifier "iVar3") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);\n    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;\n    param_3[1] = param_3[1] + param_2;\n  }" ({ "{") (expression_statement "memcpy((void *)(param_3[1] + *param_3),param_1,param_2);" (call_expression "memcpy((void *)(param_3[1] + *param_3),param_1,param_2)" (identifier "memcpy") (argument_list "((void *)(param_3[1] + *param_3),param_1,param_2)" (( "(") (cast_expression "(void *)(param_3[1] + *param_3)" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_3[1] + *param_3)" (( "(") (binary_expression "param_3[1] + *param_3" (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]")) (+ "+") (pointer_expression "*param_3" (* "*") (identifier "param_3"))) () ")"))) (, ",") (identifier "param_1") (, ",") (identifier "param_2") () ")"))) (; ";")) (expression_statement "*(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;" (assignment_expression "*(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0" (pointer_expression "*(undefined1 *)(*param_3 + param_2 + param_3[1])" (* "*") (cast_expression "(undefined1 *)(*param_3 + param_2 + param_3[1])" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*param_3 + param_2 + param_3[1])" (( "(") (binary_expression "*param_3 + param_2 + param_3[1]" (binary_expression "*param_3 + param_2" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (+ "+") (identifier "param_2")) (+ "+") (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]"))) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_3[1] = param_3[1] + param_2;" (assignment_expression "param_3[1] = param_3[1] + param_2" (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]")) (= "=") (binary_expression "param_3[1] + param_2" (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]")) (+ "+") (identifier "param_2"))) (; ";")) (} "}"))) (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 *s,size_t l,void *opaque)

{
}


(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: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (subscript_expression argument: (identifier) index: (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (number_literal) right: (identifier)))))) consequence: (compound_statement (do_statement body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (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: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (return_statement))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (pointer_expression argument: (identifier))))) (identifier) (identifier)))) (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: (binary_expression left: (pointer_expression argument: (identifier)) right: (identifier)) right: (subscript_expression argument: (identifier) index: (number_literal)))))) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier)))))) (return_statement))))

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

void MASKED(void *param_1,size_t param_2,int *param_3)

{
  uint uVar1;
  void *pvVar2;
  int iVar3;
  uint __size;
  
  __size = param_3[2];
  iVar3 = param_3[3];
  uVar1 = param_2 + 1 + param_3[1];
  if (__size < uVar1) {
    if (iVar3 != 0) {
      return;
    }
    if ((__size != 0) || (__size = 2, 2 < uVar1)) {
      do {
        __size = __size * 2;
      } while (__size < uVar1);
    }
    pvVar2 = realloc((void *)*param_3,__size);
    if (pvVar2 == (void *)0x0) {
      free((void *)*param_3);
      *param_3 = 0;
      param_3[1] = 0;
      param_3[2] = 0;
      param_3[3] = 1;
      return;
    }
    *param_3 = (int)pvVar2;
    iVar3 = param_3[3];
    param_3[2] = __size;
  }
  if (iVar3 == 0) {
    memcpy((void *)(param_3[1] + *param_3),param_1,param_2);
    *(undefined1 *)(*param_3 + param_2 + param_3[1]) = 0;
    param_3[1] = param_3[1] + param_2;
  }
  return;
}

