
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* std::string::_M_mutate(unsigned int, unsigned int, char const*, unsigned int) */

void __thiscall
std::string::_M_mutate(string *this,uint param_1,uint param_2,char *param_3,uint param_4)

{
  undefined1 *__dest;
  string *psVar1;
  uint uVar2;
  size_t __n;
  uint local_20 [3];
  undefined4 uStack_14;
  
  uStack_14 = 0x1eeab9;
  __n = *(int *)(this + 4) - (param_1 + param_2);
  local_20[0] = (param_4 - param_2) + *(int *)(this + 4);
  if (this + 8 == *(string **)this) {
    uVar2 = 0xf;
  }
  else {
    uVar2 = *(uint *)(this + 8);
  }
  __dest = (undefined1 *)_M_create(this,local_20,uVar2);
  if (param_1 != 0) {
    if (param_1 == 1) {
      *__dest = **(undefined1 **)this;
    }
    else {
      memcpy(__dest,*(undefined1 **)this,param_1);
    }
  }
  if ((param_3 != (char *)0x0) && (param_4 != 0)) {
    if (param_4 == 1) {
      __dest[param_1] = *param_3;
    }
    else {
      memcpy(__dest + param_1,param_3,param_4);
    }
  }
  psVar1 = *(string **)this;
  if (__n != 0) {
    if (__n == 1) {
      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];
      psVar1 = *(string **)this;
    }
    else {
      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);
      psVar1 = *(string **)this;
    }
  }
  if (this + 8 != psVar1) {
    operator_delete(psVar1);
  }
  *(undefined1 **)this = __dest;
  *(uint *)(this + 8) = local_20[0];
  return;
}



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

void FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)

{
  undefined1 *__dest;
  undefined1 *__src;
  int *piVar1;
  int iVar2;
  size_t __n;
  int local_20 [3];
  undefined4 uStack_14;
  
  uStack_14 = 0x1eeab9;
  __n = param_1[1] - (param_2 + param_3);
  local_20[0] = (param_5 - param_3) + param_1[1];
  if (param_1 + 2 == (int *)*param_1) {
    iVar2 = 0xf;
  }
  else {
    iVar2 = param_1[2];
  }
  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);
  if (param_2 != 0) {
    if (param_2 == 1) {
      *__dest = *(undefined1 *)*param_1;
    }
    else {
      memcpy(__dest,(undefined1 *)*param_1,param_2);
    }
  }
  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {
    if (param_5 == 1) {
      __dest[param_2] = *param_4;
    }
    else {
      memcpy(__dest + param_2,param_4,param_5);
    }
  }
  piVar1 = (int *)*param_1;
  if (__n != 0) {
    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);
    if (__n == 1) {
      __dest[param_2 + param_5] = *__src;
      piVar1 = (int *)*param_1;
    }
    else {
      memcpy(__dest + param_2 + param_5,__src,__n);
      piVar1 = (int *)*param_1;
    }
  }
  if (param_1 + 2 != piVar1) {
    FUN_001e6dc0(piVar1);
  }
  *param_1 = (int)__dest;
  param_1[2] = local_20[0];
  return;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00035840
ADD EBX,0x1a0547
SUB ESP,0x2c
MOV EBP,dword ptr [ESP + 0x40]
MOV EAX,dword ptr [ESP + 0x48]
MOV ESI,dword ptr [ESP + 0x44]
MOV ECX,dword ptr [EBP + 0x4]
LEA EDX,[ESI + EAX*0x1]
MOV EDI,ECX
MOV dword ptr [ESP + 0xc],EDX
SUB EDI,EDX
MOV dword ptr [ESP + 0x4],EDI
MOV EDI,dword ptr [ESP + 0x50]
SUB EDI,EAX
MOV EAX,EDI
ADD EAX,ECX
MOV dword ptr [ESP + 0x1c],EAX
LEA EAX,[EBP + 0x8]
MOV dword ptr [ESP + 0x8],EAX
CMP EAX,dword ptr [EBP]
JZ 0x001eebe0
MOV EAX,dword ptr [EBP + 0x8]
SUB ESP,0x4
PUSH EAX
LEA EAX,[ESP + 0x24]
PUSH EAX
PUSH EBP
CALL 0x001ee4d0
ADD ESP,0x10
MOV EDI,EAX
TEST ESI,ESI
JZ 0x001eeb33
MOV EAX,dword ptr [EBP]
CMP ESI,0x1
JZ 0x001eebd0
SUB ESP,0x4
PUSH ESI
PUSH EAX
PUSH EDI
CALL 0x000295c0
ADD ESP,0x10
MOV EDX,dword ptr [ESP + 0x4c]
TEST EDX,EDX
JZ 0x001eeb65
MOV EAX,dword ptr [ESP + 0x50]
TEST EAX,EAX
JZ 0x001eeb65
CMP dword ptr [ESP + 0x50],0x1
LEA EAX,[EDI + ESI*0x1]
JZ 0x001eebf0
SUB ESP,0x4
PUSH dword ptr [ESP + 0x54]
PUSH dword ptr [ESP + 0x54]
PUSH EAX
CALL 0x000295c0
ADD ESP,0x10
MOV ECX,dword ptr [ESP + 0x4]
MOV EAX,dword ptr [EBP]
TEST ECX,ECX
JZ 0x001eeb93
ADD ESI,dword ptr [ESP + 0x50]
ADD EAX,dword ptr [ESP + 0xc]
ADD ESI,EDI
CMP ECX,0x1
JZ 0x001eebc0
SUB ESP,0x4
PUSH dword ptr [ESP + 0x8]
PUSH EAX
PUSH ESI
CALL 0x000295c0
MOV EAX,dword ptr [EBP]
ADD ESP,0x10
CMP dword ptr [ESP + 0x8],EAX
JZ 0x001eeba5
SUB ESP,0xc
PUSH EAX
CALL 0x001e6dc0
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0x1c]
MOV dword ptr [EBP],EDI
MOV dword ptr [EBP + 0x8],EAX
ADD ESP,0x2c
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOVZX EAX,byte ptr [EAX]
MOV byte ptr [ESI],AL
MOV EAX,dword ptr [EBP]
JMP 0x001eeb93
MOVZX EAX,byte ptr [EAX]
MOV byte ptr [EDI],AL
JMP 0x001eeb33
MOV EAX,0xf
JMP 0x001eeb01
MOV EDX,dword ptr [ESP + 0x4c]
MOVZX EDX,byte ptr [EDX]
MOV byte ptr [EAX],DL
JMP 0x001eeb65
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)\n\n{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}\n\n" comment (function_definition "void FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)\n\n{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}" primitive_type (function_declarator "FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)" identifier (parameter_list "(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)" ( (parameter_declaration "int *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 identifier) , (parameter_declaration "undefined1 *param_4" type_identifier (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "size_t param_5" primitive_type identifier) ))) (compound_statement "{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}" { (declaration "undefined1 *__dest;" type_identifier (pointer_declarator "*__dest" * identifier) ;) (declaration "undefined1 *__src;" type_identifier (pointer_declarator "*__src" * identifier) ;) (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "size_t __n;" primitive_type identifier ;) (declaration "int local_20 [3];" primitive_type (array_declarator "local_20 [3]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x1eeab9;" (assignment_expression "uStack_14 = 0x1eeab9" identifier = number_literal) ;) (expression_statement "__n = param_1[1] - (param_2 + param_3);" (assignment_expression "__n = param_1[1] - (param_2 + param_3)" identifier = (binary_expression "param_1[1] - (param_2 + param_3)" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (parenthesized_expression "(param_2 + param_3)" ( (binary_expression "param_2 + param_3" identifier + identifier) )))) ;) (expression_statement "local_20[0] = (param_5 - param_3) + param_1[1];" (assignment_expression "local_20[0] = (param_5 - param_3) + param_1[1]" (subscript_expression "local_20[0]" identifier [ number_literal ]) = (binary_expression "(param_5 - param_3) + param_1[1]" (parenthesized_expression "(param_5 - param_3)" ( (binary_expression "param_5 - param_3" identifier - identifier) )) + (subscript_expression "param_1[1]" identifier [ number_literal ]))) ;) (if_statement "if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }" if (parenthesized_expression "(param_1 + 2 == (int *)*param_1)" ( (binary_expression "param_1 + 2 == (int *)*param_1" (binary_expression "param_1 + 2" identifier + number_literal) == (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) )) (compound_statement "{\n    iVar2 = 0xf;\n  }" { (expression_statement "iVar2 = 0xf;" (assignment_expression "iVar2 = 0xf" identifier = number_literal) ;) }) (else_clause "else {\n    iVar2 = param_1[2];\n  }" else (compound_statement "{\n    iVar2 = param_1[2];\n  }" { (expression_statement "iVar2 = param_1[2];" (assignment_expression "iVar2 = param_1[2]" identifier = (subscript_expression "param_1[2]" identifier [ number_literal ])) ;) }))) (expression_statement "__dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);" (assignment_expression "__dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2)" identifier = (cast_expression "(undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_001ee4d0(param_1,local_20,iVar2)" identifier (argument_list "(param_1,local_20,iVar2)" ( identifier , identifier , identifier ))))) ;) (if_statement "if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }" if (parenthesized_expression "(param_2 != 0)" ( (binary_expression "param_2 != 0" identifier != number_literal) )) (compound_statement "{\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }" { (if_statement "if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" if (parenthesized_expression "(param_2 == 1)" ( (binary_expression "param_2 == 1" identifier == number_literal) )) (compound_statement "{\n      *__dest = *(undefined1 *)*param_1;\n    }" { (expression_statement "*__dest = *(undefined1 *)*param_1;" (assignment_expression "*__dest = *(undefined1 *)*param_1" (pointer_expression "*__dest" * identifier) = (pointer_expression "*(undefined1 *)*param_1" * (cast_expression "(undefined1 *)*param_1" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier)))) ;) }) (else_clause "else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" else (compound_statement "{\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" { (expression_statement "memcpy(__dest,(undefined1 *)*param_1,param_2);" (call_expression "memcpy(__dest,(undefined1 *)*param_1,param_2)" identifier (argument_list "(__dest,(undefined1 *)*param_1,param_2)" ( identifier , (cast_expression "(undefined1 *)*param_1" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier)) , identifier ))) ;) }))) })) (if_statement "if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }" if (parenthesized_expression "((param_4 != (undefined1 *)0x0) && (param_5 != 0))" ( (binary_expression "(param_4 != (undefined1 *)0x0) && (param_5 != 0)" (parenthesized_expression "(param_4 != (undefined1 *)0x0)" ( (binary_expression "param_4 != (undefined1 *)0x0" identifier != (cast_expression "(undefined1 *)0x0" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(param_5 != 0)" ( (binary_expression "param_5 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }" { (if_statement "if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }" if (parenthesized_expression "(param_5 == 1)" ( (binary_expression "param_5 == 1" identifier == number_literal) )) (compound_statement "{\n      __dest[param_2] = *param_4;\n    }" { (expression_statement "__dest[param_2] = *param_4;" (assignment_expression "__dest[param_2] = *param_4" (subscript_expression "__dest[param_2]" identifier [ identifier ]) = (pointer_expression "*param_4" * identifier)) ;) }) (else_clause "else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }" else (compound_statement "{\n      memcpy(__dest + param_2,param_4,param_5);\n    }" { (expression_statement "memcpy(__dest + param_2,param_4,param_5);" (call_expression "memcpy(__dest + param_2,param_4,param_5)" identifier (argument_list "(__dest + param_2,param_4,param_5)" ( (binary_expression "__dest + param_2" identifier + identifier) , identifier , identifier ))) ;) }))) })) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" identifier = (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }" if (parenthesized_expression "(__n != 0)" ( (binary_expression "__n != 0" identifier != number_literal) )) (compound_statement "{\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }" { (expression_statement "__src = (undefined1 *)((int)piVar1 + param_2 + param_3);" (assignment_expression "__src = (undefined1 *)((int)piVar1 + param_2 + param_3)" identifier = (cast_expression "(undefined1 *)((int)piVar1 + param_2 + param_3)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)piVar1 + param_2 + param_3)" ( (binary_expression "(int)piVar1 + param_2 + param_3" (binary_expression "(int)piVar1 + param_2" (cast_expression "(int)piVar1" ( (type_descriptor "int" primitive_type) ) identifier) + identifier) + identifier) )))) ;) (if_statement "if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" if (parenthesized_expression "(__n == 1)" ( (binary_expression "__n == 1" identifier == number_literal) )) (compound_statement "{\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }" { (expression_statement "__dest[param_2 + param_5] = *__src;" (assignment_expression "__dest[param_2 + param_5] = *__src" (subscript_expression "__dest[param_2 + param_5]" identifier [ (binary_expression "param_2 + param_5" identifier + identifier) ]) = (pointer_expression "*__src" * identifier)) ;) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" identifier = (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) }) (else_clause "else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" else (compound_statement "{\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" { (expression_statement "memcpy(__dest + param_2 + param_5,__src,__n);" (call_expression "memcpy(__dest + param_2 + param_5,__src,__n)" identifier (argument_list "(__dest + param_2 + param_5,__src,__n)" ( (binary_expression "__dest + param_2 + param_5" (binary_expression "__dest + param_2" identifier + identifier) + identifier) , identifier , identifier ))) ;) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" identifier = (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) }))) })) (if_statement "if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }" if (parenthesized_expression "(param_1 + 2 != piVar1)" ( (binary_expression "param_1 + 2 != piVar1" (binary_expression "param_1 + 2" identifier + number_literal) != identifier) )) (compound_statement "{\n    FUN_001e6dc0(piVar1);\n  }" { (expression_statement "FUN_001e6dc0(piVar1);" (call_expression "FUN_001e6dc0(piVar1)" identifier (argument_list "(piVar1)" ( identifier ))) ;) })) (expression_statement "*param_1 = (int)__dest;" (assignment_expression "*param_1 = (int)__dest" (pointer_expression "*param_1" * identifier) = (cast_expression "(int)__dest" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "param_1[2] = local_20[0];" (assignment_expression "param_1[2] = local_20[0]" (subscript_expression "param_1[2]" identifier [ number_literal ]) = (subscript_expression "local_20[0]" identifier [ number_literal ])) ;) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* std::string::_M_mutate(unsigned int, unsigned int, char const*, unsigned int) */\n\nvoid __thiscall\nstd::string::_M_mutate(string *this,uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  undefined1 *__dest;\n  string *psVar1;\n  uint uVar2;\n  size_t __n;\n  uint local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = *(int *)(this + 4) - (param_1 + param_2);\n  local_20[0] = (param_4 - param_2) + *(int *)(this + 4);\n  if (this + 8 == *(string **)this) {\n    uVar2 = 0xf;\n  }\n  else {\n    uVar2 = *(uint *)(this + 8);\n  }\n  __dest = (undefined1 *)_M_create(this,local_20,uVar2);\n  if (param_1 != 0) {\n    if (param_1 == 1) {\n      *__dest = **(undefined1 **)this;\n    }\n    else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }\n  }\n  if ((param_3 != (char *)0x0) && (param_4 != 0)) {\n    if (param_4 == 1) {\n      __dest[param_1] = *param_3;\n    }\n    else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }\n  }\n  psVar1 = *(string **)this;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }\n    else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }\n  }\n  if (this + 8 != psVar1) {\n    operator_delete(psVar1);\n  }\n  *(undefined1 **)this = __dest;\n  *(uint *)(this + 8) = local_20[0];\n  return;\n}\n\n" comment comment (function_definition "void __thiscall\nstd::string::_M_mutate(string *this,uint param_1,uint param_2,char *param_3,uint param_4)\n\n{\n  undefined1 *__dest;\n  string *psVar1;\n  uint uVar2;\n  size_t __n;\n  uint local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = *(int *)(this + 4) - (param_1 + param_2);\n  local_20[0] = (param_4 - param_2) + *(int *)(this + 4);\n  if (this + 8 == *(string **)this) {\n    uVar2 = 0xf;\n  }\n  else {\n    uVar2 = *(uint *)(this + 8);\n  }\n  __dest = (undefined1 *)_M_create(this,local_20,uVar2);\n  if (param_1 != 0) {\n    if (param_1 == 1) {\n      *__dest = **(undefined1 **)this;\n    }\n    else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }\n  }\n  if ((param_3 != (char *)0x0) && (param_4 != 0)) {\n    if (param_4 == 1) {\n      __dest[param_1] = *param_3;\n    }\n    else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }\n  }\n  psVar1 = *(string **)this;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }\n    else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }\n  }\n  if (this + 8 != psVar1) {\n    operator_delete(psVar1);\n  }\n  *(undefined1 **)this = __dest;\n  *(uint *)(this + 8) = local_20[0];\n  return;\n}" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::string::" identifier : : identifier : :) (function_declarator "_M_mutate(string *this,uint param_1,uint param_2,char *param_3,uint param_4)" identifier (parameter_list "(string *this,uint param_1,uint param_2,char *param_3,uint param_4)" ( (parameter_declaration "string *this" type_identifier (pointer_declarator "*this" * identifier)) , (parameter_declaration "uint param_1" type_identifier identifier) , (parameter_declaration "uint param_2" type_identifier identifier) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "uint param_4" type_identifier identifier) ))) (compound_statement "{\n  undefined1 *__dest;\n  string *psVar1;\n  uint uVar2;\n  size_t __n;\n  uint local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = *(int *)(this + 4) - (param_1 + param_2);\n  local_20[0] = (param_4 - param_2) + *(int *)(this + 4);\n  if (this + 8 == *(string **)this) {\n    uVar2 = 0xf;\n  }\n  else {\n    uVar2 = *(uint *)(this + 8);\n  }\n  __dest = (undefined1 *)_M_create(this,local_20,uVar2);\n  if (param_1 != 0) {\n    if (param_1 == 1) {\n      *__dest = **(undefined1 **)this;\n    }\n    else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }\n  }\n  if ((param_3 != (char *)0x0) && (param_4 != 0)) {\n    if (param_4 == 1) {\n      __dest[param_1] = *param_3;\n    }\n    else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }\n  }\n  psVar1 = *(string **)this;\n  if (__n != 0) {\n    if (__n == 1) {\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }\n    else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }\n  }\n  if (this + 8 != psVar1) {\n    operator_delete(psVar1);\n  }\n  *(undefined1 **)this = __dest;\n  *(uint *)(this + 8) = local_20[0];\n  return;\n}" { (declaration "undefined1 *__dest;" type_identifier (pointer_declarator "*__dest" * identifier) ;) (declaration "string *psVar1;" type_identifier (pointer_declarator "*psVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "size_t __n;" primitive_type identifier ;) (declaration "uint local_20 [3];" type_identifier (array_declarator "local_20 [3]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x1eeab9;" (assignment_expression "uStack_14 = 0x1eeab9" identifier = number_literal) ;) (expression_statement "__n = *(int *)(this + 4) - (param_1 + param_2);" (assignment_expression "__n = *(int *)(this + 4) - (param_1 + param_2)" identifier = (binary_expression "*(int *)(this + 4) - (param_1 + param_2)" (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) )))) - (parenthesized_expression "(param_1 + param_2)" ( (binary_expression "param_1 + param_2" identifier + identifier) )))) ;) (expression_statement "local_20[0] = (param_4 - param_2) + *(int *)(this + 4);" (assignment_expression "local_20[0] = (param_4 - param_2) + *(int *)(this + 4)" (subscript_expression "local_20[0]" identifier [ number_literal ]) = (binary_expression "(param_4 - param_2) + *(int *)(this + 4)" (parenthesized_expression "(param_4 - param_2)" ( (binary_expression "param_4 - param_2" identifier - identifier) )) + (pointer_expression "*(int *)(this + 4)" * (cast_expression "(int *)(this + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) )))))) ;) (if_statement "if (this + 8 == *(string **)this) {\n    uVar2 = 0xf;\n  }\n  else {\n    uVar2 = *(uint *)(this + 8);\n  }" if (parenthesized_expression "(this + 8 == *(string **)this)" ( (binary_expression "this + 8 == *(string **)this" (binary_expression "this + 8" identifier + number_literal) == (pointer_expression "*(string **)this" * (cast_expression "(string **)this" ( (type_descriptor "string **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) )) (compound_statement "{\n    uVar2 = 0xf;\n  }" { (expression_statement "uVar2 = 0xf;" (assignment_expression "uVar2 = 0xf" identifier = number_literal) ;) }) (else_clause "else {\n    uVar2 = *(uint *)(this + 8);\n  }" else (compound_statement "{\n    uVar2 = *(uint *)(this + 8);\n  }" { (expression_statement "uVar2 = *(uint *)(this + 8);" (assignment_expression "uVar2 = *(uint *)(this + 8)" identifier = (pointer_expression "*(uint *)(this + 8)" * (cast_expression "(uint *)(this + 8)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) ))))) ;) }))) (expression_statement "__dest = (undefined1 *)_M_create(this,local_20,uVar2);" (assignment_expression "__dest = (undefined1 *)_M_create(this,local_20,uVar2)" identifier = (cast_expression "(undefined1 *)_M_create(this,local_20,uVar2)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "_M_create(this,local_20,uVar2)" identifier (argument_list "(this,local_20,uVar2)" ( identifier , identifier , identifier ))))) ;) (if_statement "if (param_1 != 0) {\n    if (param_1 == 1) {\n      *__dest = **(undefined1 **)this;\n    }\n    else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }\n  }" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (compound_statement "{\n    if (param_1 == 1) {\n      *__dest = **(undefined1 **)this;\n    }\n    else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }\n  }" { (if_statement "if (param_1 == 1) {\n      *__dest = **(undefined1 **)this;\n    }\n    else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }" if (parenthesized_expression "(param_1 == 1)" ( (binary_expression "param_1 == 1" identifier == number_literal) )) (compound_statement "{\n      *__dest = **(undefined1 **)this;\n    }" { (expression_statement "*__dest = **(undefined1 **)this;" (assignment_expression "*__dest = **(undefined1 **)this" (pointer_expression "*__dest" * identifier) = (pointer_expression "**(undefined1 **)this" * (pointer_expression "*(undefined1 **)this" * (cast_expression "(undefined1 **)this" ( (type_descriptor "undefined1 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)))) ;) }) (else_clause "else {\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }" else (compound_statement "{\n      memcpy(__dest,*(undefined1 **)this,param_1);\n    }" { (expression_statement "memcpy(__dest,*(undefined1 **)this,param_1);" (call_expression "memcpy(__dest,*(undefined1 **)this,param_1)" identifier (argument_list "(__dest,*(undefined1 **)this,param_1)" ( identifier , (pointer_expression "*(undefined1 **)this" * (cast_expression "(undefined1 **)this" ( (type_descriptor "undefined1 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) , identifier ))) ;) }))) })) (if_statement "if ((param_3 != (char *)0x0) && (param_4 != 0)) {\n    if (param_4 == 1) {\n      __dest[param_1] = *param_3;\n    }\n    else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }\n  }" if (parenthesized_expression "((param_3 != (char *)0x0) && (param_4 != 0))" ( (binary_expression "(param_3 != (char *)0x0) && (param_4 != 0)" (parenthesized_expression "(param_3 != (char *)0x0)" ( (binary_expression "param_3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(param_4 != 0)" ( (binary_expression "param_4 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    if (param_4 == 1) {\n      __dest[param_1] = *param_3;\n    }\n    else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }\n  }" { (if_statement "if (param_4 == 1) {\n      __dest[param_1] = *param_3;\n    }\n    else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }" if (parenthesized_expression "(param_4 == 1)" ( (binary_expression "param_4 == 1" identifier == number_literal) )) (compound_statement "{\n      __dest[param_1] = *param_3;\n    }" { (expression_statement "__dest[param_1] = *param_3;" (assignment_expression "__dest[param_1] = *param_3" (subscript_expression "__dest[param_1]" identifier [ identifier ]) = (pointer_expression "*param_3" * identifier)) ;) }) (else_clause "else {\n      memcpy(__dest + param_1,param_3,param_4);\n    }" else (compound_statement "{\n      memcpy(__dest + param_1,param_3,param_4);\n    }" { (expression_statement "memcpy(__dest + param_1,param_3,param_4);" (call_expression "memcpy(__dest + param_1,param_3,param_4)" identifier (argument_list "(__dest + param_1,param_3,param_4)" ( (binary_expression "__dest + param_1" identifier + identifier) , identifier , identifier ))) ;) }))) })) (expression_statement "psVar1 = *(string **)this;" (assignment_expression "psVar1 = *(string **)this" identifier = (pointer_expression "*(string **)this" * (cast_expression "(string **)this" ( (type_descriptor "string **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) (if_statement "if (__n != 0) {\n    if (__n == 1) {\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }\n    else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }\n  }" if (parenthesized_expression "(__n != 0)" ( (binary_expression "__n != 0" identifier != number_literal) )) (compound_statement "{\n    if (__n == 1) {\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }\n    else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }\n  }" { (if_statement "if (__n == 1) {\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }\n    else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }" if (parenthesized_expression "(__n == 1)" ( (binary_expression "__n == 1" identifier == number_literal) )) (compound_statement "{\n      *(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];\n      psVar1 = *(string **)this;\n    }" { (expression_statement "*(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2];" (assignment_expression "*(string *)(__dest + param_1 + param_4) = psVar1[param_1 + param_2]" (pointer_expression "*(string *)(__dest + param_1 + param_4)" * (cast_expression "(string *)(__dest + param_1 + param_4)" ( (type_descriptor "string *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(__dest + param_1 + param_4)" ( (binary_expression "__dest + param_1 + param_4" (binary_expression "__dest + param_1" identifier + identifier) + identifier) )))) = (subscript_expression "psVar1[param_1 + param_2]" identifier [ (binary_expression "param_1 + param_2" identifier + identifier) ])) ;) (expression_statement "psVar1 = *(string **)this;" (assignment_expression "psVar1 = *(string **)this" identifier = (pointer_expression "*(string **)this" * (cast_expression "(string **)this" ( (type_descriptor "string **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) }) (else_clause "else {\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }" else (compound_statement "{\n      memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);\n      psVar1 = *(string **)this;\n    }" { (expression_statement "memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n);" (call_expression "memcpy((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n)" identifier (argument_list "((string *)(__dest + param_1 + param_4),psVar1 + param_1 + param_2,__n)" ( (cast_expression "(string *)(__dest + param_1 + param_4)" ( (type_descriptor "string *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(__dest + param_1 + param_4)" ( (binary_expression "__dest + param_1 + param_4" (binary_expression "__dest + param_1" identifier + identifier) + identifier) ))) , (binary_expression "psVar1 + param_1 + param_2" (binary_expression "psVar1 + param_1" identifier + identifier) + identifier) , identifier ))) ;) (expression_statement "psVar1 = *(string **)this;" (assignment_expression "psVar1 = *(string **)this" identifier = (pointer_expression "*(string **)this" * (cast_expression "(string **)this" ( (type_descriptor "string **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier))) ;) }))) })) (if_statement "if (this + 8 != psVar1) {\n    operator_delete(psVar1);\n  }" if (parenthesized_expression "(this + 8 != psVar1)" ( (binary_expression "this + 8 != psVar1" (binary_expression "this + 8" identifier + number_literal) != identifier) )) (compound_statement "{\n    operator_delete(psVar1);\n  }" { (expression_statement "operator_delete(psVar1);" (call_expression "operator_delete(psVar1)" identifier (argument_list "(psVar1)" ( identifier ))) ;) })) (expression_statement "*(undefined1 **)this = __dest;" (assignment_expression "*(undefined1 **)this = __dest" (pointer_expression "*(undefined1 **)this" * (cast_expression "(undefined1 **)this" ( (type_descriptor "undefined1 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = identifier) ;) (expression_statement "*(uint *)(this + 8) = local_20[0];" (assignment_expression "*(uint *)(this + 8) = local_20[0]" (pointer_expression "*(uint *)(this + 8)" * (cast_expression "(uint *)(this + 8)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) )))) = (subscript_expression "local_20[0]" identifier [ number_literal ])) ;) (return_statement "return;" return ;) })))
(translation_unit "void FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)\n\n{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}\n\n" (function_definition "void FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)\n\n{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}" primitive_type (function_declarator "FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)" identifier (parameter_list "(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)" ( (parameter_declaration "int *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 identifier) , (parameter_declaration "undefined1 *param_4" type_identifier (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "size_t param_5" primitive_type identifier) ))) (compound_statement "{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}" { (declaration "undefined1 *__dest;" type_identifier (pointer_declarator "*__dest" * identifier) ;) (declaration "undefined1 *__src;" type_identifier (pointer_declarator "*__src" * identifier) ;) (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "size_t __n;" primitive_type identifier ;) (declaration "int local_20 [3];" primitive_type (array_declarator "local_20 [3]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x1eeab9;" (assignment_expression "uStack_14 = 0x1eeab9" identifier = number_literal) ;) (expression_statement "__n = param_1[1] - (param_2 + param_3);" (assignment_expression "__n = param_1[1] - (param_2 + param_3)" identifier = (binary_expression "param_1[1] - (param_2 + param_3)" (subscript_expression "param_1[1]" identifier [ number_literal ]) - (parenthesized_expression "(param_2 + param_3)" ( (binary_expression "param_2 + param_3" identifier + identifier) )))) ;) (expression_statement "local_20[0] = (param_5 - param_3) + param_1[1];" (assignment_expression "local_20[0] = (param_5 - param_3) + param_1[1]" (subscript_expression "local_20[0]" identifier [ number_literal ]) = (binary_expression "(param_5 - param_3) + param_1[1]" (parenthesized_expression "(param_5 - param_3)" ( (binary_expression "param_5 - param_3" identifier - identifier) )) + (subscript_expression "param_1[1]" identifier [ number_literal ]))) ;) (if_statement "if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }" if (parenthesized_expression "(param_1 + 2 == (int *)*param_1)" ( (binary_expression "param_1 + 2 == (int *)*param_1" (binary_expression "param_1 + 2" identifier + number_literal) == (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) )) (compound_statement "{\n    iVar2 = 0xf;\n  }" { (expression_statement "iVar2 = 0xf;" (assignment_expression "iVar2 = 0xf" identifier = number_literal) ;) }) (else_clause "else {\n    iVar2 = param_1[2];\n  }" else (compound_statement "{\n    iVar2 = param_1[2];\n  }" { (expression_statement "iVar2 = param_1[2];" (assignment_expression "iVar2 = param_1[2]" identifier = (subscript_expression "param_1[2]" identifier [ number_literal ])) ;) }))) (expression_statement "__dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);" (assignment_expression "__dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2)" identifier = (cast_expression "(undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_001ee4d0(param_1,local_20,iVar2)" identifier (argument_list "(param_1,local_20,iVar2)" ( identifier , identifier , identifier ))))) ;) (if_statement "if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }" if (parenthesized_expression "(param_2 != 0)" ( (binary_expression "param_2 != 0" identifier != number_literal) )) (compound_statement "{\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }" { (if_statement "if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" if (parenthesized_expression "(param_2 == 1)" ( (binary_expression "param_2 == 1" identifier == number_literal) )) (compound_statement "{\n      *__dest = *(undefined1 *)*param_1;\n    }" { (expression_statement "*__dest = *(undefined1 *)*param_1;" (assignment_expression "*__dest = *(undefined1 *)*param_1" (pointer_expression "*__dest" * identifier) = (pointer_expression "*(undefined1 *)*param_1" * (cast_expression "(undefined1 *)*param_1" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier)))) ;) }) (else_clause "else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" else (compound_statement "{\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" { (expression_statement "memcpy(__dest,(undefined1 *)*param_1,param_2);" (call_expression "memcpy(__dest,(undefined1 *)*param_1,param_2)" identifier (argument_list "(__dest,(undefined1 *)*param_1,param_2)" ( identifier , (cast_expression "(undefined1 *)*param_1" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier)) , identifier ))) ;) }))) })) (if_statement "if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }" if (parenthesized_expression "((param_4 != (undefined1 *)0x0) && (param_5 != 0))" ( (binary_expression "(param_4 != (undefined1 *)0x0) && (param_5 != 0)" (parenthesized_expression "(param_4 != (undefined1 *)0x0)" ( (binary_expression "param_4 != (undefined1 *)0x0" identifier != (cast_expression "(undefined1 *)0x0" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(param_5 != 0)" ( (binary_expression "param_5 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }" { (if_statement "if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }" if (parenthesized_expression "(param_5 == 1)" ( (binary_expression "param_5 == 1" identifier == number_literal) )) (compound_statement "{\n      __dest[param_2] = *param_4;\n    }" { (expression_statement "__dest[param_2] = *param_4;" (assignment_expression "__dest[param_2] = *param_4" (subscript_expression "__dest[param_2]" identifier [ identifier ]) = (pointer_expression "*param_4" * identifier)) ;) }) (else_clause "else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }" else (compound_statement "{\n      memcpy(__dest + param_2,param_4,param_5);\n    }" { (expression_statement "memcpy(__dest + param_2,param_4,param_5);" (call_expression "memcpy(__dest + param_2,param_4,param_5)" identifier (argument_list "(__dest + param_2,param_4,param_5)" ( (binary_expression "__dest + param_2" identifier + identifier) , identifier , identifier ))) ;) }))) })) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" identifier = (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (if_statement "if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }" if (parenthesized_expression "(__n != 0)" ( (binary_expression "__n != 0" identifier != number_literal) )) (compound_statement "{\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }" { (expression_statement "__src = (undefined1 *)((int)piVar1 + param_2 + param_3);" (assignment_expression "__src = (undefined1 *)((int)piVar1 + param_2 + param_3)" identifier = (cast_expression "(undefined1 *)((int)piVar1 + param_2 + param_3)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)piVar1 + param_2 + param_3)" ( (binary_expression "(int)piVar1 + param_2 + param_3" (binary_expression "(int)piVar1 + param_2" (cast_expression "(int)piVar1" ( (type_descriptor "int" primitive_type) ) identifier) + identifier) + identifier) )))) ;) (if_statement "if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" if (parenthesized_expression "(__n == 1)" ( (binary_expression "__n == 1" identifier == number_literal) )) (compound_statement "{\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }" { (expression_statement "__dest[param_2 + param_5] = *__src;" (assignment_expression "__dest[param_2 + param_5] = *__src" (subscript_expression "__dest[param_2 + param_5]" identifier [ (binary_expression "param_2 + param_5" identifier + identifier) ]) = (pointer_expression "*__src" * identifier)) ;) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" identifier = (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) }) (else_clause "else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" else (compound_statement "{\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" { (expression_statement "memcpy(__dest + param_2 + param_5,__src,__n);" (call_expression "memcpy(__dest + param_2 + param_5,__src,__n)" identifier (argument_list "(__dest + param_2 + param_5,__src,__n)" ( (binary_expression "__dest + param_2 + param_5" (binary_expression "__dest + param_2" identifier + identifier) + identifier) , identifier , identifier ))) ;) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" identifier = (cast_expression "(int *)*param_1" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) }))) })) (if_statement "if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }" if (parenthesized_expression "(param_1 + 2 != piVar1)" ( (binary_expression "param_1 + 2 != piVar1" (binary_expression "param_1 + 2" identifier + number_literal) != identifier) )) (compound_statement "{\n    FUN_001e6dc0(piVar1);\n  }" { (expression_statement "FUN_001e6dc0(piVar1);" (call_expression "FUN_001e6dc0(piVar1)" identifier (argument_list "(piVar1)" ( identifier ))) ;) })) (expression_statement "*param_1 = (int)__dest;" (assignment_expression "*param_1 = (int)__dest" (pointer_expression "*param_1" * identifier) = (cast_expression "(int)__dest" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "param_1[2] = local_20[0];" (assignment_expression "param_1[2] = local_20[0]" (subscript_expression "param_1[2]" identifier [ number_literal ]) = (subscript_expression "local_20[0]" 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 (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (binary_expression (subscript_expression IDENT [ LIT ]) - (parenthesized_expression ( (binary_expression IDENT + IDENT) )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression (parenthesized_expression ( (binary_expression IDENT - IDENT) )) + (subscript_expression IDENT [ LIT ]))) ;) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression IDENT + LIT) == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) }))) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT)))) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT)) , IDENT ))) ;) }))) })) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ IDENT ]) = (pointer_expression * IDENT)) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (binary_expression IDENT + IDENT) , IDENT , IDENT ))) ;) }))) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) + IDENT) + IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ (binary_expression IDENT + IDENT) ]) = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (binary_expression (binary_expression IDENT + IDENT) + IDENT) , IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) }))) })) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression IDENT + LIT) != IDENT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (subscript_expression IDENT [ LIT ])) ;) (return_statement return ;) })))
(function_definition "void FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)\n\n{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}" (primitive_type "void") (function_declarator "FUN_001eeab0(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)" (identifier "FUN_001eeab0") (parameter_list "(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)" (( "(") (parameter_declaration "int *param_1" (primitive_type "int") (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") (identifier "param_3")) (, ",") (parameter_declaration "undefined1 *param_4" (type_identifier "undefined1") (pointer_declarator "*param_4" (* "*") (identifier "param_4"))) (, ",") (parameter_declaration "size_t param_5" (primitive_type "size_t") (identifier "param_5")) () ")"))) (compound_statement "{\n  undefined1 *__dest;\n  undefined1 *__src;\n  int *piVar1;\n  int iVar2;\n  size_t __n;\n  int local_20 [3];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x1eeab9;\n  __n = param_1[1] - (param_2 + param_3);\n  local_20[0] = (param_5 - param_3) + param_1[1];\n  if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }\n  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);\n  if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }\n  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }\n  piVar1 = (int *)*param_1;\n  if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }\n  if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }\n  *param_1 = (int)__dest;\n  param_1[2] = local_20[0];\n  return;\n}" ({ "{") (declaration "undefined1 *__dest;" (type_identifier "undefined1") (pointer_declarator "*__dest" (* "*") (identifier "__dest")) (; ";")) (declaration "undefined1 *__src;" (type_identifier "undefined1") (pointer_declarator "*__src" (* "*") (identifier "__src")) (; ";")) (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "size_t __n;" (primitive_type "size_t") (identifier "__n") (; ";")) (declaration "int local_20 [3];" (primitive_type "int") (array_declarator "local_20 [3]" (identifier "local_20") ([ "[") (number_literal "3") (] "]")) (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x1eeab9;" (assignment_expression "uStack_14 = 0x1eeab9" (identifier "uStack_14") (= "=") (number_literal "0x1eeab9")) (; ";")) (expression_statement "__n = param_1[1] - (param_2 + param_3);" (assignment_expression "__n = param_1[1] - (param_2 + param_3)" (identifier "__n") (= "=") (binary_expression "param_1[1] - (param_2 + param_3)" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (- "-") (parenthesized_expression "(param_2 + param_3)" (( "(") (binary_expression "param_2 + param_3" (identifier "param_2") (+ "+") (identifier "param_3")) () ")")))) (; ";")) (expression_statement "local_20[0] = (param_5 - param_3) + param_1[1];" (assignment_expression "local_20[0] = (param_5 - param_3) + param_1[1]" (subscript_expression "local_20[0]" (identifier "local_20") ([ "[") (number_literal "0") (] "]")) (= "=") (binary_expression "(param_5 - param_3) + param_1[1]" (parenthesized_expression "(param_5 - param_3)" (( "(") (binary_expression "param_5 - param_3" (identifier "param_5") (- "-") (identifier "param_3")) () ")")) (+ "+") (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")))) (; ";")) (if_statement "if (param_1 + 2 == (int *)*param_1) {\n    iVar2 = 0xf;\n  }\n  else {\n    iVar2 = param_1[2];\n  }" (if "if") (parenthesized_expression "(param_1 + 2 == (int *)*param_1)" (( "(") (binary_expression "param_1 + 2 == (int *)*param_1" (binary_expression "param_1 + 2" (identifier "param_1") (+ "+") (number_literal "2")) (== "==") (cast_expression "(int *)*param_1" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) () ")")) (compound_statement "{\n    iVar2 = 0xf;\n  }" ({ "{") (expression_statement "iVar2 = 0xf;" (assignment_expression "iVar2 = 0xf" (identifier "iVar2") (= "=") (number_literal "0xf")) (; ";")) (} "}")) (else_clause "else {\n    iVar2 = param_1[2];\n  }" (else "else") (compound_statement "{\n    iVar2 = param_1[2];\n  }" ({ "{") (expression_statement "iVar2 = param_1[2];" (assignment_expression "iVar2 = param_1[2]" (identifier "iVar2") (= "=") (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]"))) (; ";")) (} "}")))) (expression_statement "__dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);" (assignment_expression "__dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2)" (identifier "__dest") (= "=") (cast_expression "(undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_001ee4d0(param_1,local_20,iVar2)" (identifier "FUN_001ee4d0") (argument_list "(param_1,local_20,iVar2)" (( "(") (identifier "param_1") (, ",") (identifier "local_20") (, ",") (identifier "iVar2") () ")"))))) (; ";")) (if_statement "if (param_2 != 0) {\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }" (if "if") (parenthesized_expression "(param_2 != 0)" (( "(") (binary_expression "param_2 != 0" (identifier "param_2") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }\n  }" ({ "{") (if_statement "if (param_2 == 1) {\n      *__dest = *(undefined1 *)*param_1;\n    }\n    else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" (if "if") (parenthesized_expression "(param_2 == 1)" (( "(") (binary_expression "param_2 == 1" (identifier "param_2") (== "==") (number_literal "1")) () ")")) (compound_statement "{\n      *__dest = *(undefined1 *)*param_1;\n    }" ({ "{") (expression_statement "*__dest = *(undefined1 *)*param_1;" (assignment_expression "*__dest = *(undefined1 *)*param_1" (pointer_expression "*__dest" (* "*") (identifier "__dest")) (= "=") (pointer_expression "*(undefined1 *)*param_1" (* "*") (cast_expression "(undefined1 *)*param_1" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1"))))) (; ";")) (} "}")) (else_clause "else {\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" (else "else") (compound_statement "{\n      memcpy(__dest,(undefined1 *)*param_1,param_2);\n    }" ({ "{") (expression_statement "memcpy(__dest,(undefined1 *)*param_1,param_2);" (call_expression "memcpy(__dest,(undefined1 *)*param_1,param_2)" (identifier "memcpy") (argument_list "(__dest,(undefined1 *)*param_1,param_2)" (( "(") (identifier "__dest") (, ",") (cast_expression "(undefined1 *)*param_1" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (, ",") (identifier "param_2") () ")"))) (; ";")) (} "}")))) (} "}"))) (if_statement "if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }" (if "if") (parenthesized_expression "((param_4 != (undefined1 *)0x0) && (param_5 != 0))" (( "(") (binary_expression "(param_4 != (undefined1 *)0x0) && (param_5 != 0)" (parenthesized_expression "(param_4 != (undefined1 *)0x0)" (( "(") (binary_expression "param_4 != (undefined1 *)0x0" (identifier "param_4") (!= "!=") (cast_expression "(undefined1 *)0x0" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(param_5 != 0)" (( "(") (binary_expression "param_5 != 0" (identifier "param_5") (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n    if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }\n  }" ({ "{") (if_statement "if (param_5 == 1) {\n      __dest[param_2] = *param_4;\n    }\n    else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }" (if "if") (parenthesized_expression "(param_5 == 1)" (( "(") (binary_expression "param_5 == 1" (identifier "param_5") (== "==") (number_literal "1")) () ")")) (compound_statement "{\n      __dest[param_2] = *param_4;\n    }" ({ "{") (expression_statement "__dest[param_2] = *param_4;" (assignment_expression "__dest[param_2] = *param_4" (subscript_expression "__dest[param_2]" (identifier "__dest") ([ "[") (identifier "param_2") (] "]")) (= "=") (pointer_expression "*param_4" (* "*") (identifier "param_4"))) (; ";")) (} "}")) (else_clause "else {\n      memcpy(__dest + param_2,param_4,param_5);\n    }" (else "else") (compound_statement "{\n      memcpy(__dest + param_2,param_4,param_5);\n    }" ({ "{") (expression_statement "memcpy(__dest + param_2,param_4,param_5);" (call_expression "memcpy(__dest + param_2,param_4,param_5)" (identifier "memcpy") (argument_list "(__dest + param_2,param_4,param_5)" (( "(") (binary_expression "__dest + param_2" (identifier "__dest") (+ "+") (identifier "param_2")) (, ",") (identifier "param_4") (, ",") (identifier "param_5") () ")"))) (; ";")) (} "}")))) (} "}"))) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" (identifier "piVar1") (= "=") (cast_expression "(int *)*param_1" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (if_statement "if (__n != 0) {\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }" (if "if") (parenthesized_expression "(__n != 0)" (( "(") (binary_expression "__n != 0" (identifier "__n") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);\n    if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }\n  }" ({ "{") (expression_statement "__src = (undefined1 *)((int)piVar1 + param_2 + param_3);" (assignment_expression "__src = (undefined1 *)((int)piVar1 + param_2 + param_3)" (identifier "__src") (= "=") (cast_expression "(undefined1 *)((int)piVar1 + param_2 + param_3)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)piVar1 + param_2 + param_3)" (( "(") (binary_expression "(int)piVar1 + param_2 + param_3" (binary_expression "(int)piVar1 + param_2" (cast_expression "(int)piVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "piVar1")) (+ "+") (identifier "param_2")) (+ "+") (identifier "param_3")) () ")")))) (; ";")) (if_statement "if (__n == 1) {\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }\n    else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" (if "if") (parenthesized_expression "(__n == 1)" (( "(") (binary_expression "__n == 1" (identifier "__n") (== "==") (number_literal "1")) () ")")) (compound_statement "{\n      __dest[param_2 + param_5] = *__src;\n      piVar1 = (int *)*param_1;\n    }" ({ "{") (expression_statement "__dest[param_2 + param_5] = *__src;" (assignment_expression "__dest[param_2 + param_5] = *__src" (subscript_expression "__dest[param_2 + param_5]" (identifier "__dest") ([ "[") (binary_expression "param_2 + param_5" (identifier "param_2") (+ "+") (identifier "param_5")) (] "]")) (= "=") (pointer_expression "*__src" (* "*") (identifier "__src"))) (; ";")) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" (identifier "piVar1") (= "=") (cast_expression "(int *)*param_1" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (} "}")) (else_clause "else {\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" (else "else") (compound_statement "{\n      memcpy(__dest + param_2 + param_5,__src,__n);\n      piVar1 = (int *)*param_1;\n    }" ({ "{") (expression_statement "memcpy(__dest + param_2 + param_5,__src,__n);" (call_expression "memcpy(__dest + param_2 + param_5,__src,__n)" (identifier "memcpy") (argument_list "(__dest + param_2 + param_5,__src,__n)" (( "(") (binary_expression "__dest + param_2 + param_5" (binary_expression "__dest + param_2" (identifier "__dest") (+ "+") (identifier "param_2")) (+ "+") (identifier "param_5")) (, ",") (identifier "__src") (, ",") (identifier "__n") () ")"))) (; ";")) (expression_statement "piVar1 = (int *)*param_1;" (assignment_expression "piVar1 = (int *)*param_1" (identifier "piVar1") (= "=") (cast_expression "(int *)*param_1" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (} "}")))) (} "}"))) (if_statement "if (param_1 + 2 != piVar1) {\n    FUN_001e6dc0(piVar1);\n  }" (if "if") (parenthesized_expression "(param_1 + 2 != piVar1)" (( "(") (binary_expression "param_1 + 2 != piVar1" (binary_expression "param_1 + 2" (identifier "param_1") (+ "+") (number_literal "2")) (!= "!=") (identifier "piVar1")) () ")")) (compound_statement "{\n    FUN_001e6dc0(piVar1);\n  }" ({ "{") (expression_statement "FUN_001e6dc0(piVar1);" (call_expression "FUN_001e6dc0(piVar1)" (identifier "FUN_001e6dc0") (argument_list "(piVar1)" (( "(") (identifier "piVar1") () ")"))) (; ";")) (} "}"))) (expression_statement "*param_1 = (int)__dest;" (assignment_expression "*param_1 = (int)__dest" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(int)__dest" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "__dest"))) (; ";")) (expression_statement "param_1[2] = local_20[0];" (assignment_expression "param_1[2] = local_20[0]" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (= "=") (subscript_expression "local_20[0]" (identifier "local_20") ([ "[") (number_literal "0") (] "]"))) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* std::string::_M_mutate(unsigned int, unsigned int, char const*, unsigned int) */

void __thiscall
std::type_1::function_1(type_1 *var_1,type_2 var_2,type_2 var_3,char *var_7,type_2 var_4)

{
  type_3 *var_8;
  type_1 *var_10;
  type_2 uVar2;
  size_t var_9;
  type_2 local_20 [3];
  type_4 uStack_14;
  
  uStack_14 = 0x1eeab9;
  var_9 = *(int *)(var_1 + 4) - (var_2 + var_3);
  local_20[0] = (var_4 - var_3) + *(int *)(var_1 + 4);
  if (var_1 + 8 == *(type_1 **)var_1) {
    uVar2 = 0xf;
  }
  else {
    uVar2 = *(type_2 *)(var_1 + 8);
  }
  var_8 = (type_3 *)var_5(var_1,local_20,uVar2);
  if (var_2 != 0) {
    if (var_2 == 1) {
      *var_8 = **(type_3 **)var_1;
    }
    else {
      var_6(var_8,*(type_3 **)var_1,var_2);
    }
  }
  if ((var_7 != (char *)0x0) && (var_4 != 0)) {
    if (var_4 == 1) {
      var_8[var_2] = *var_7;
    }
    else {
      var_6(var_8 + var_2,var_7,var_4);
    }
  }
  var_10 = *(type_1 **)var_1;
  if (var_9 != 0) {
    if (var_9 == 1) {
      *(type_1 *)(var_8 + var_2 + var_4) = var_10[var_2 + var_3];
      var_10 = *(type_1 **)var_1;
    }
    else {
      var_6((type_1 *)(var_8 + var_2 + var_4),var_10 + var_2 + var_3,var_9);
      var_10 = *(type_1 **)var_1;
    }
  }
  if (var_1 + 8 != var_10) {
    var_11(var_10);
  }
  *(type_3 **)var_1 = var_8;
  *(type_2 *)(var_1 + 8) = local_20[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: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (parenthesized_expression (binary_expression left: (identifier) right: (identifier)))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) right: (subscript_expression argument: (identifier) index: (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal))))))) (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 (identifier) (identifier) (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))))) alternative: (else_clause (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))) (identifier))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (pointer_expression argument: (identifier))))) alternative: (else_clause (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (identifier)) (identifier) (identifier))))))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (identifier)) right: (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (binary_expression left: (identifier) right: (identifier))) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier)))))) alternative: (else_clause (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (identifier)) (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier)))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (identifier))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (subscript_expression argument: (identifier) index: (number_literal)))) (return_statement))))

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

void MASKED(int *param_1,size_t param_2,int param_3,undefined1 *param_4,size_t param_5)

{
  undefined1 *__dest;
  undefined1 *__src;
  int *piVar1;
  int iVar2;
  size_t __n;
  int local_20 [3];
  undefined4 uStack_14;
  
  uStack_14 = 0x1eeab9;
  __n = param_1[1] - (param_2 + param_3);
  local_20[0] = (param_5 - param_3) + param_1[1];
  if (param_1 + 2 == (int *)*param_1) {
    iVar2 = 0xf;
  }
  else {
    iVar2 = param_1[2];
  }
  __dest = (undefined1 *)FUN_001ee4d0(param_1,local_20,iVar2);
  if (param_2 != 0) {
    if (param_2 == 1) {
      *__dest = *(undefined1 *)*param_1;
    }
    else {
      memcpy(__dest,(undefined1 *)*param_1,param_2);
    }
  }
  if ((param_4 != (undefined1 *)0x0) && (param_5 != 0)) {
    if (param_5 == 1) {
      __dest[param_2] = *param_4;
    }
    else {
      memcpy(__dest + param_2,param_4,param_5);
    }
  }
  piVar1 = (int *)*param_1;
  if (__n != 0) {
    __src = (undefined1 *)((int)piVar1 + param_2 + param_3);
    if (__n == 1) {
      __dest[param_2 + param_5] = *__src;
      piVar1 = (int *)*param_1;
    }
    else {
      memcpy(__dest + param_2 + param_5,__src,__n);
      piVar1 = (int *)*param_1;
    }
  }
  if (param_1 + 2 != piVar1) {
    FUN_001e6dc0(piVar1);
  }
  *param_1 = (int)__dest;
  param_1[2] = local_20[0];
  return;
}

