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

char * reconcat(char *optr,char *first,...)

{
  size_t sVar1;
  int iVar2;
  int *piVar3;
  char *pcVar4;
  char *local_20;
  
  if (first == (char *)0x0) {
    pcVar4 = (char *)xmalloc(1);
    local_20 = pcVar4;
  }
  else {
    iVar2 = 0;
    pcVar4 = first;
    piVar3 = (int *)&stack0x0000000c;
    do {
      sVar1 = strlen(pcVar4);
      iVar2 = iVar2 + sVar1;
      pcVar4 = (char *)*piVar3;
      piVar3 = piVar3 + 1;
    } while (pcVar4 != (char *)0x0);
    local_20 = (char *)xmalloc(iVar2 + 1);
    piVar3 = (int *)&stack0x0000000c;
    pcVar4 = local_20;
    do {
      sVar1 = strlen(first);
      memcpy(pcVar4,first,sVar1);
      first = (char *)*piVar3;
      pcVar4 = pcVar4 + sVar1;
      piVar3 = piVar3 + 1;
    } while (first != (char *)0x0);
  }
  *pcVar4 = '\0';
  if (optr != (char *)0x0) {
    free(optr);
  }
  return local_20;
}



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

undefined1 * FUN_00068640(void *param_1,char *param_2)

{
  char *__s;
  size_t sVar1;
  int iVar2;
  int *piVar3;
  undefined1 *__dest;
  undefined1 *local_20;
  
  if (param_2 == (char *)0x0) {
    __dest = (undefined1 *)FUN_0006b190(1);
    local_20 = __dest;
  }
  else {
    iVar2 = 0;
    __s = param_2;
    piVar3 = (int *)&stack0x0000000c;
    do {
      sVar1 = strlen(__s);
      iVar2 = iVar2 + sVar1;
      __s = (char *)*piVar3;
      piVar3 = piVar3 + 1;
    } while (__s != (char *)0x0);
    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);
    piVar3 = (int *)&stack0x0000000c;
    __dest = local_20;
    do {
      sVar1 = strlen(param_2);
      memcpy(__dest,param_2,sVar1);
      param_2 = (char *)*piVar3;
      __dest = __dest + sVar1;
      piVar3 = piVar3 + 1;
    } while (param_2 != (char *)0x0);
  }
  *__dest = 0;
  if (param_1 != (void *)0x0) {
    free(param_1);
  }
  return local_20;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00013f70
ADD EBX,0x4b9b7
SUB ESP,0x1c
MOV ESI,dword ptr [ESP + 0x34]
LEA EAX,[ESP + 0x38]
MOV dword ptr [ESP + 0x8],EAX
TEST ESI,ESI
JZ 0x00068700
MOV EDI,EAX
XOR EBP,EBP
MOV EAX,ESI
LEA ESI,[ESI]
SUB ESP,0xc
ADD EDI,0x4
PUSH EAX
CALL 0x00013260
ADD ESP,0x10
ADD EBP,EAX
MOV EAX,dword ptr [EDI + -0x4]
TEST EAX,EAX
JNZ 0x00068670
SUB ESP,0xc
ADD EBP,0x1
PUSH EBP
CALL 0x0006b190
MOV EBP,dword ptr [ESP + 0x18]
MOV dword ptr [ESP + 0x1c],EAX
MOV EDI,EAX
ADD ESP,0x10
LEA ESI,[ESI]
SUB ESP,0xc
ADD EBP,0x4
PUSH ESI
CALL 0x00013260
ADD ESP,0xc
PUSH EAX
MOV dword ptr [ESP + 0x10],EAX
PUSH ESI
PUSH EDI
CALL 0x000130c0
MOV ECX,dword ptr [ESP + 0x18]
MOV ESI,dword ptr [EBP + -0x4]
ADD ESP,0x10
ADD EDI,ECX
TEST ESI,ESI
JNZ 0x000686a8
MOV EAX,dword ptr [ESP + 0x30]
MOV byte ptr [EDI],0x0
TEST EAX,EAX
JZ 0x000686ed
SUB ESP,0xc
PUSH dword ptr [ESP + 0x3c]
CALL 0x000130a0
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0xc]
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0xc
PUSH 0x1
CALL 0x0006b190
ADD ESP,0x10
MOV EDI,EAX
MOV dword ptr [ESP + 0xc],EAX
JMP 0x000686d3
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined1 * FUN_00068640(void *param_1,char *param_2)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}\n\n" comment (function_definition "undefined1 * FUN_00068640(void *param_1,char *param_2)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}" type_identifier (pointer_declarator "* FUN_00068640(void *param_1,char *param_2)" * (function_declarator "FUN_00068640(void *param_1,char *param_2)" identifier (parameter_list "(void *param_1,char *param_2)" ( (parameter_declaration "void *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) )))) (compound_statement "{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}" { (declaration "char *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (declaration "undefined1 *__dest;" type_identifier (pointer_declarator "*__dest" * identifier) ;) (declaration "undefined1 *local_20;" type_identifier (pointer_declarator "*local_20" * identifier) ;) (if_statement "if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" if (parenthesized_expression "(param_2 == (char *)0x0)" ( (binary_expression "param_2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }" { (expression_statement "__dest = (undefined1 *)FUN_0006b190(1);" (assignment_expression "__dest = (undefined1 *)FUN_0006b190(1)" identifier = (cast_expression "(undefined1 *)FUN_0006b190(1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0006b190(1)" identifier (argument_list "(1)" ( number_literal ))))) ;) (expression_statement "local_20 = __dest;" (assignment_expression "local_20 = __dest" identifier = identifier) ;) }) (else_clause "else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" else (compound_statement "{\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" { (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) (expression_statement "__s = param_2;" (assignment_expression "__s = param_2" identifier = identifier) ;) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" identifier = (cast_expression "(int *)&stack0x0000000c" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "&stack0x0000000c" & identifier))) ;) (do_statement "do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);" do (compound_statement "{\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    }" { (expression_statement "sVar1 = strlen(__s);" (assignment_expression "sVar1 = strlen(__s)" identifier = (call_expression "strlen(__s)" identifier (argument_list "(__s)" ( identifier )))) ;) (expression_statement "iVar2 = iVar2 + sVar1;" (assignment_expression "iVar2 = iVar2 + sVar1" identifier = (binary_expression "iVar2 + sVar1" identifier + identifier)) ;) (expression_statement "__s = (char *)*piVar3;" (assignment_expression "__s = (char *)*piVar3" identifier = (cast_expression "(char *)*piVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" identifier = (binary_expression "piVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(__s != (char *)0x0)" ( (binary_expression "__s != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) (expression_statement "local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);" (assignment_expression "local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1)" identifier = (cast_expression "(undefined1 *)FUN_0006b190(iVar2 + 1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0006b190(iVar2 + 1)" identifier (argument_list "(iVar2 + 1)" ( (binary_expression "iVar2 + 1" identifier + number_literal) ))))) ;) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" identifier = (cast_expression "(int *)&stack0x0000000c" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "&stack0x0000000c" & identifier))) ;) (expression_statement "__dest = local_20;" (assignment_expression "__dest = local_20" identifier = identifier) ;) (do_statement "do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);" do (compound_statement "{\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    }" { (expression_statement "sVar1 = strlen(param_2);" (assignment_expression "sVar1 = strlen(param_2)" identifier = (call_expression "strlen(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "memcpy(__dest,param_2,sVar1);" (call_expression "memcpy(__dest,param_2,sVar1)" identifier (argument_list "(__dest,param_2,sVar1)" ( identifier , identifier , identifier ))) ;) (expression_statement "param_2 = (char *)*piVar3;" (assignment_expression "param_2 = (char *)*piVar3" identifier = (cast_expression "(char *)*piVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "__dest = __dest + sVar1;" (assignment_expression "__dest = __dest + sVar1" identifier = (binary_expression "__dest + sVar1" identifier + identifier)) ;) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" identifier = (binary_expression "piVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_2 != (char *)0x0)" ( (binary_expression "param_2 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) }))) (expression_statement "*__dest = 0;" (assignment_expression "*__dest = 0" (pointer_expression "*__dest" * identifier) = number_literal) ;) (if_statement "if (param_1 != (void *)0x0) {\n    free(param_1);\n  }" if (parenthesized_expression "(param_1 != (void *)0x0)" ( (binary_expression "param_1 != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    free(param_1);\n  }" { (expression_statement "free(param_1);" (call_expression "free(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) })) (return_statement "return local_20;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nchar * reconcat(char *optr,char *first,...)\n\n{\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  char *pcVar4;\n  char *local_20;\n  \n  if (first == (char *)0x0) {\n    pcVar4 = (char *)xmalloc(1);\n    local_20 = pcVar4;\n  }\n  else {\n    iVar2 = 0;\n    pcVar4 = first;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);\n    local_20 = (char *)xmalloc(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    pcVar4 = local_20;\n    do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);\n  }\n  *pcVar4 = '\0';\n  if (optr != (char *)0x0) {\n    free(optr);\n  }\n  return local_20;\n}\n\n" comment comment (function_definition "char * reconcat(char *optr,char *first,...)\n\n{\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  char *pcVar4;\n  char *local_20;\n  \n  if (first == (char *)0x0) {\n    pcVar4 = (char *)xmalloc(1);\n    local_20 = pcVar4;\n  }\n  else {\n    iVar2 = 0;\n    pcVar4 = first;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);\n    local_20 = (char *)xmalloc(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    pcVar4 = local_20;\n    do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);\n  }\n  *pcVar4 = '\0';\n  if (optr != (char *)0x0) {\n    free(optr);\n  }\n  return local_20;\n}" primitive_type (pointer_declarator "* reconcat(char *optr,char *first,...)" * (function_declarator "reconcat(char *optr,char *first,...)" identifier (parameter_list "(char *optr,char *first,...)" ( (parameter_declaration "char *optr" primitive_type (pointer_declarator "*optr" * identifier)) , (parameter_declaration "char *first" primitive_type (pointer_declarator "*first" * identifier)) , (variadic_parameter "..." ...) )))) (compound_statement "{\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  char *pcVar4;\n  char *local_20;\n  \n  if (first == (char *)0x0) {\n    pcVar4 = (char *)xmalloc(1);\n    local_20 = pcVar4;\n  }\n  else {\n    iVar2 = 0;\n    pcVar4 = first;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);\n    local_20 = (char *)xmalloc(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    pcVar4 = local_20;\n    do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);\n  }\n  *pcVar4 = '\0';\n  if (optr != (char *)0x0) {\n    free(optr);\n  }\n  return local_20;\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (declaration "char *local_20;" primitive_type (pointer_declarator "*local_20" * identifier) ;) (if_statement "if (first == (char *)0x0) {\n    pcVar4 = (char *)xmalloc(1);\n    local_20 = pcVar4;\n  }\n  else {\n    iVar2 = 0;\n    pcVar4 = first;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);\n    local_20 = (char *)xmalloc(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    pcVar4 = local_20;\n    do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);\n  }" if (parenthesized_expression "(first == (char *)0x0)" ( (binary_expression "first == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    pcVar4 = (char *)xmalloc(1);\n    local_20 = pcVar4;\n  }" { (expression_statement "pcVar4 = (char *)xmalloc(1);" (assignment_expression "pcVar4 = (char *)xmalloc(1)" identifier = (cast_expression "(char *)xmalloc(1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(1)" identifier (argument_list "(1)" ( number_literal ))))) ;) (expression_statement "local_20 = pcVar4;" (assignment_expression "local_20 = pcVar4" identifier = identifier) ;) }) (else_clause "else {\n    iVar2 = 0;\n    pcVar4 = first;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);\n    local_20 = (char *)xmalloc(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    pcVar4 = local_20;\n    do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);\n  }" else (compound_statement "{\n    iVar2 = 0;\n    pcVar4 = first;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);\n    local_20 = (char *)xmalloc(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    pcVar4 = local_20;\n    do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);\n  }" { (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) (expression_statement "pcVar4 = first;" (assignment_expression "pcVar4 = first" identifier = identifier) ;) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" identifier = (cast_expression "(int *)&stack0x0000000c" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "&stack0x0000000c" & identifier))) ;) (do_statement "do {\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (pcVar4 != (char *)0x0);" do (compound_statement "{\n      sVar1 = strlen(pcVar4);\n      iVar2 = iVar2 + sVar1;\n      pcVar4 = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    }" { (expression_statement "sVar1 = strlen(pcVar4);" (assignment_expression "sVar1 = strlen(pcVar4)" identifier = (call_expression "strlen(pcVar4)" identifier (argument_list "(pcVar4)" ( identifier )))) ;) (expression_statement "iVar2 = iVar2 + sVar1;" (assignment_expression "iVar2 = iVar2 + sVar1" identifier = (binary_expression "iVar2 + sVar1" identifier + identifier)) ;) (expression_statement "pcVar4 = (char *)*piVar3;" (assignment_expression "pcVar4 = (char *)*piVar3" identifier = (cast_expression "(char *)*piVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" identifier = (binary_expression "piVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(pcVar4 != (char *)0x0)" ( (binary_expression "pcVar4 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) (expression_statement "local_20 = (char *)xmalloc(iVar2 + 1);" (assignment_expression "local_20 = (char *)xmalloc(iVar2 + 1)" identifier = (cast_expression "(char *)xmalloc(iVar2 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(iVar2 + 1)" identifier (argument_list "(iVar2 + 1)" ( (binary_expression "iVar2 + 1" identifier + number_literal) ))))) ;) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" identifier = (cast_expression "(int *)&stack0x0000000c" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "&stack0x0000000c" & identifier))) ;) (expression_statement "pcVar4 = local_20;" (assignment_expression "pcVar4 = local_20" identifier = identifier) ;) (do_statement "do {\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (first != (char *)0x0);" do (compound_statement "{\n      sVar1 = strlen(first);\n      memcpy(pcVar4,first,sVar1);\n      first = (char *)*piVar3;\n      pcVar4 = pcVar4 + sVar1;\n      piVar3 = piVar3 + 1;\n    }" { (expression_statement "sVar1 = strlen(first);" (assignment_expression "sVar1 = strlen(first)" identifier = (call_expression "strlen(first)" identifier (argument_list "(first)" ( identifier )))) ;) (expression_statement "memcpy(pcVar4,first,sVar1);" (call_expression "memcpy(pcVar4,first,sVar1)" identifier (argument_list "(pcVar4,first,sVar1)" ( identifier , identifier , identifier ))) ;) (expression_statement "first = (char *)*piVar3;" (assignment_expression "first = (char *)*piVar3" identifier = (cast_expression "(char *)*piVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "pcVar4 = pcVar4 + sVar1;" (assignment_expression "pcVar4 = pcVar4 + sVar1" identifier = (binary_expression "pcVar4 + sVar1" identifier + identifier)) ;) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" identifier = (binary_expression "piVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(first != (char *)0x0)" ( (binary_expression "first != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) }))) (expression_statement "*pcVar4 = '\0';" (assignment_expression "*pcVar4 = '\0'" (pointer_expression "*pcVar4" * identifier) = (char_literal "'\0'" ' escape_sequence ')) ;) (if_statement "if (optr != (char *)0x0) {\n    free(optr);\n  }" if (parenthesized_expression "(optr != (char *)0x0)" ( (binary_expression "optr != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    free(optr);\n  }" { (expression_statement "free(optr);" (call_expression "free(optr)" identifier (argument_list "(optr)" ( identifier ))) ;) })) (return_statement "return local_20;" return identifier ;) })))
(translation_unit "undefined1 * FUN_00068640(void *param_1,char *param_2)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}\n\n" (function_definition "undefined1 * FUN_00068640(void *param_1,char *param_2)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}" type_identifier (pointer_declarator "* FUN_00068640(void *param_1,char *param_2)" * (function_declarator "FUN_00068640(void *param_1,char *param_2)" identifier (parameter_list "(void *param_1,char *param_2)" ( (parameter_declaration "void *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) )))) (compound_statement "{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}" { (declaration "char *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (declaration "undefined1 *__dest;" type_identifier (pointer_declarator "*__dest" * identifier) ;) (declaration "undefined1 *local_20;" type_identifier (pointer_declarator "*local_20" * identifier) ;) (if_statement "if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" if (parenthesized_expression "(param_2 == (char *)0x0)" ( (binary_expression "param_2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }" { (expression_statement "__dest = (undefined1 *)FUN_0006b190(1);" (assignment_expression "__dest = (undefined1 *)FUN_0006b190(1)" identifier = (cast_expression "(undefined1 *)FUN_0006b190(1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0006b190(1)" identifier (argument_list "(1)" ( number_literal ))))) ;) (expression_statement "local_20 = __dest;" (assignment_expression "local_20 = __dest" identifier = identifier) ;) }) (else_clause "else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" else (compound_statement "{\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" { (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) (expression_statement "__s = param_2;" (assignment_expression "__s = param_2" identifier = identifier) ;) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" identifier = (cast_expression "(int *)&stack0x0000000c" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "&stack0x0000000c" & identifier))) ;) (do_statement "do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);" do (compound_statement "{\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    }" { (expression_statement "sVar1 = strlen(__s);" (assignment_expression "sVar1 = strlen(__s)" identifier = (call_expression "strlen(__s)" identifier (argument_list "(__s)" ( identifier )))) ;) (expression_statement "iVar2 = iVar2 + sVar1;" (assignment_expression "iVar2 = iVar2 + sVar1" identifier = (binary_expression "iVar2 + sVar1" identifier + identifier)) ;) (expression_statement "__s = (char *)*piVar3;" (assignment_expression "__s = (char *)*piVar3" identifier = (cast_expression "(char *)*piVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" identifier = (binary_expression "piVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(__s != (char *)0x0)" ( (binary_expression "__s != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) (expression_statement "local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);" (assignment_expression "local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1)" identifier = (cast_expression "(undefined1 *)FUN_0006b190(iVar2 + 1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0006b190(iVar2 + 1)" identifier (argument_list "(iVar2 + 1)" ( (binary_expression "iVar2 + 1" identifier + number_literal) ))))) ;) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" identifier = (cast_expression "(int *)&stack0x0000000c" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "&stack0x0000000c" & identifier))) ;) (expression_statement "__dest = local_20;" (assignment_expression "__dest = local_20" identifier = identifier) ;) (do_statement "do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);" do (compound_statement "{\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    }" { (expression_statement "sVar1 = strlen(param_2);" (assignment_expression "sVar1 = strlen(param_2)" identifier = (call_expression "strlen(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "memcpy(__dest,param_2,sVar1);" (call_expression "memcpy(__dest,param_2,sVar1)" identifier (argument_list "(__dest,param_2,sVar1)" ( identifier , identifier , identifier ))) ;) (expression_statement "param_2 = (char *)*piVar3;" (assignment_expression "param_2 = (char *)*piVar3" identifier = (cast_expression "(char *)*piVar3" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "__dest = __dest + sVar1;" (assignment_expression "__dest = __dest + sVar1" identifier = (binary_expression "__dest + sVar1" identifier + identifier)) ;) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" identifier = (binary_expression "piVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_2 != (char *)0x0)" ( (binary_expression "param_2 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) }))) (expression_statement "*__dest = 0;" (assignment_expression "*__dest = 0" (pointer_expression "*__dest" * identifier) = number_literal) ;) (if_statement "if (param_1 != (void *)0x0) {\n    free(param_1);\n  }" if (parenthesized_expression "(param_1 != (void *)0x0)" ( (binary_expression "param_1 != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    free(param_1);\n  }" { (expression_statement "free(param_1);" (call_expression "free(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) })) (return_statement "return local_20;" return identifier ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) )))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( LIT ))))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression & IDENT))) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression & IDENT))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) ;) }))) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (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 ( IDENT ))) ;) })) (return_statement return IDENT ;) })))
(function_definition "undefined1 * FUN_00068640(void *param_1,char *param_2)\n\n{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}" (type_identifier "undefined1") (pointer_declarator "* FUN_00068640(void *param_1,char *param_2)" (* "*") (function_declarator "FUN_00068640(void *param_1,char *param_2)" (identifier "FUN_00068640") (parameter_list "(void *param_1,char *param_2)" (( "(") (parameter_declaration "void *param_1" (primitive_type "void") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "char *param_2" (primitive_type "char") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")")))) (compound_statement "{\n  char *__s;\n  size_t sVar1;\n  int iVar2;\n  int *piVar3;\n  undefined1 *__dest;\n  undefined1 *local_20;\n  \n  if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }\n  *__dest = 0;\n  if (param_1 != (void *)0x0) {\n    free(param_1);\n  }\n  return local_20;\n}" ({ "{") (declaration "char *__s;" (primitive_type "char") (pointer_declarator "*__s" (* "*") (identifier "__s")) (; ";")) (declaration "size_t sVar1;" (primitive_type "size_t") (identifier "sVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int *piVar3;" (primitive_type "int") (pointer_declarator "*piVar3" (* "*") (identifier "piVar3")) (; ";")) (declaration "undefined1 *__dest;" (type_identifier "undefined1") (pointer_declarator "*__dest" (* "*") (identifier "__dest")) (; ";")) (declaration "undefined1 *local_20;" (type_identifier "undefined1") (pointer_declarator "*local_20" (* "*") (identifier "local_20")) (; ";")) (if_statement "if (param_2 == (char *)0x0) {\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }\n  else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" (if "if") (parenthesized_expression "(param_2 == (char *)0x0)" (( "(") (binary_expression "param_2 == (char *)0x0" (identifier "param_2") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    __dest = (undefined1 *)FUN_0006b190(1);\n    local_20 = __dest;\n  }" ({ "{") (expression_statement "__dest = (undefined1 *)FUN_0006b190(1);" (assignment_expression "__dest = (undefined1 *)FUN_0006b190(1)" (identifier "__dest") (= "=") (cast_expression "(undefined1 *)FUN_0006b190(1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0006b190(1)" (identifier "FUN_0006b190") (argument_list "(1)" (( "(") (number_literal "1") () ")"))))) (; ";")) (expression_statement "local_20 = __dest;" (assignment_expression "local_20 = __dest" (identifier "local_20") (= "=") (identifier "__dest")) (; ";")) (} "}")) (else_clause "else {\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" (else "else") (compound_statement "{\n    iVar2 = 0;\n    __s = param_2;\n    piVar3 = (int *)&stack0x0000000c;\n    do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);\n    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);\n    piVar3 = (int *)&stack0x0000000c;\n    __dest = local_20;\n    do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);\n  }" ({ "{") (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" (identifier "iVar2") (= "=") (number_literal "0")) (; ";")) (expression_statement "__s = param_2;" (assignment_expression "__s = param_2" (identifier "__s") (= "=") (identifier "param_2")) (; ";")) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" (identifier "piVar3") (= "=") (cast_expression "(int *)&stack0x0000000c" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "&stack0x0000000c" (& "&") (identifier "stack0x0000000c")))) (; ";")) (do_statement "do {\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    } while (__s != (char *)0x0);" (do "do") (compound_statement "{\n      sVar1 = strlen(__s);\n      iVar2 = iVar2 + sVar1;\n      __s = (char *)*piVar3;\n      piVar3 = piVar3 + 1;\n    }" ({ "{") (expression_statement "sVar1 = strlen(__s);" (assignment_expression "sVar1 = strlen(__s)" (identifier "sVar1") (= "=") (call_expression "strlen(__s)" (identifier "strlen") (argument_list "(__s)" (( "(") (identifier "__s") () ")")))) (; ";")) (expression_statement "iVar2 = iVar2 + sVar1;" (assignment_expression "iVar2 = iVar2 + sVar1" (identifier "iVar2") (= "=") (binary_expression "iVar2 + sVar1" (identifier "iVar2") (+ "+") (identifier "sVar1"))) (; ";")) (expression_statement "__s = (char *)*piVar3;" (assignment_expression "__s = (char *)*piVar3" (identifier "__s") (= "=") (cast_expression "(char *)*piVar3" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*piVar3" (* "*") (identifier "piVar3")))) (; ";")) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" (identifier "piVar3") (= "=") (binary_expression "piVar3 + 1" (identifier "piVar3") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(__s != (char *)0x0)" (( "(") (binary_expression "__s != (char *)0x0" (identifier "__s") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (; ";")) (expression_statement "local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);" (assignment_expression "local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1)" (identifier "local_20") (= "=") (cast_expression "(undefined1 *)FUN_0006b190(iVar2 + 1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0006b190(iVar2 + 1)" (identifier "FUN_0006b190") (argument_list "(iVar2 + 1)" (( "(") (binary_expression "iVar2 + 1" (identifier "iVar2") (+ "+") (number_literal "1")) () ")"))))) (; ";")) (expression_statement "piVar3 = (int *)&stack0x0000000c;" (assignment_expression "piVar3 = (int *)&stack0x0000000c" (identifier "piVar3") (= "=") (cast_expression "(int *)&stack0x0000000c" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "&stack0x0000000c" (& "&") (identifier "stack0x0000000c")))) (; ";")) (expression_statement "__dest = local_20;" (assignment_expression "__dest = local_20" (identifier "__dest") (= "=") (identifier "local_20")) (; ";")) (do_statement "do {\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    } while (param_2 != (char *)0x0);" (do "do") (compound_statement "{\n      sVar1 = strlen(param_2);\n      memcpy(__dest,param_2,sVar1);\n      param_2 = (char *)*piVar3;\n      __dest = __dest + sVar1;\n      piVar3 = piVar3 + 1;\n    }" ({ "{") (expression_statement "sVar1 = strlen(param_2);" (assignment_expression "sVar1 = strlen(param_2)" (identifier "sVar1") (= "=") (call_expression "strlen(param_2)" (identifier "strlen") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (expression_statement "memcpy(__dest,param_2,sVar1);" (call_expression "memcpy(__dest,param_2,sVar1)" (identifier "memcpy") (argument_list "(__dest,param_2,sVar1)" (( "(") (identifier "__dest") (, ",") (identifier "param_2") (, ",") (identifier "sVar1") () ")"))) (; ";")) (expression_statement "param_2 = (char *)*piVar3;" (assignment_expression "param_2 = (char *)*piVar3" (identifier "param_2") (= "=") (cast_expression "(char *)*piVar3" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*piVar3" (* "*") (identifier "piVar3")))) (; ";")) (expression_statement "__dest = __dest + sVar1;" (assignment_expression "__dest = __dest + sVar1" (identifier "__dest") (= "=") (binary_expression "__dest + sVar1" (identifier "__dest") (+ "+") (identifier "sVar1"))) (; ";")) (expression_statement "piVar3 = piVar3 + 1;" (assignment_expression "piVar3 = piVar3 + 1" (identifier "piVar3") (= "=") (binary_expression "piVar3 + 1" (identifier "piVar3") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(param_2 != (char *)0x0)" (( "(") (binary_expression "param_2 != (char *)0x0" (identifier "param_2") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (; ";")) (} "}")))) (expression_statement "*__dest = 0;" (assignment_expression "*__dest = 0" (pointer_expression "*__dest" (* "*") (identifier "__dest")) (= "=") (number_literal "0")) (; ";")) (if_statement "if (param_1 != (void *)0x0) {\n    free(param_1);\n  }" (if "if") (parenthesized_expression "(param_1 != (void *)0x0)" (( "(") (binary_expression "param_1 != (void *)0x0" (identifier "param_1") (!= "!=") (cast_expression "(void *)0x0" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    free(param_1);\n  }" ({ "{") (expression_statement "free(param_1);" (call_expression "free(param_1)" (identifier "free") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (} "}"))) (return_statement "return local_20;" (return "return") (identifier "local_20") (; ";")) (} "}")))

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

char * function_1(char *var_9,char *var_1,...)

{
  size_t var_5;
  int var_4;
  int *var_6;
  char *var_7;
  char *local_20;
  
  if (var_1 == (char *)0x0) {
    var_7 = (char *)var_2(1);
    local_20 = var_7;
  }
  else {
    var_4 = 0;
    var_7 = var_1;
    var_6 = (int *)&stack0x0000000c;
    do {
      var_5 = var_3(var_7);
      var_4 = var_4 + var_5;
      var_7 = (char *)*var_6;
      var_6 = var_6 + 1;
    } while (var_7 != (char *)0x0);
    local_20 = (char *)var_2(var_4 + 1);
    var_6 = (int *)&stack0x0000000c;
    var_7 = local_20;
    do {
      var_5 = var_3(var_1);
      var_8(var_7,var_1,var_5);
      var_1 = (char *)*var_6;
      var_7 = var_7 + var_5;
      var_6 = var_6 + 1;
    } while (var_1 != (char *)0x0);
  }
  *var_7 = '\0';
  if (var_9 != (char *)0x0) {
    var_10(var_9);
  }
  return local_20;
}


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

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

undefined1 * MASKED(void *param_1,char *param_2)

{
  char *__s;
  size_t sVar1;
  int iVar2;
  int *piVar3;
  undefined1 *__dest;
  undefined1 *local_20;
  
  if (param_2 == (char *)0x0) {
    __dest = (undefined1 *)FUN_0006b190(1);
    local_20 = __dest;
  }
  else {
    iVar2 = 0;
    __s = param_2;
    piVar3 = (int *)&stack0x0000000c;
    do {
      sVar1 = strlen(__s);
      iVar2 = iVar2 + sVar1;
      __s = (char *)*piVar3;
      piVar3 = piVar3 + 1;
    } while (__s != (char *)0x0);
    local_20 = (undefined1 *)FUN_0006b190(iVar2 + 1);
    piVar3 = (int *)&stack0x0000000c;
    __dest = local_20;
    do {
      sVar1 = strlen(param_2);
      memcpy(__dest,param_2,sVar1);
      param_2 = (char *)*piVar3;
      __dest = __dest + sVar1;
      piVar3 = piVar3 + 1;
    } while (param_2 != (char *)0x0);
  }
  *__dest = 0;
  if (param_1 != (void *)0x0) {
    free(param_1);
  }
  return local_20;
}

