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

char * read_commands_string(char *prompt)

{
  char *pcVar1;
  char *pcVar2;
  size_t len;
  char *pcVar3;
  
  if (commands_string == (char *)0x0) {
    pcVar1 = (char *)0x0;
  }
  else {
    pcVar1 = commands_string + commands_string_len;
    if (commands_string < pcVar1) {
      pcVar3 = commands_string;
      if (*commands_string == line_sep) {
        len = 0;
      }
      else {
        do {
          pcVar3 = pcVar3 + 1;
          if (pcVar1 == pcVar3) goto LAB_00042cfb;
        } while (*pcVar3 != line_sep);
        len = (int)pcVar3 - (int)commands_string;
      }
      pcVar2 = estrdup(commands_string,len);
      commands_string = pcVar3 + 1;
      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);
      return pcVar2;
    }
LAB_00042cfb:
    pcVar1 = estrdup(commands_string,commands_string_len);
    commands_string = (char *)0x0;
    commands_string_len = 0;
  }
  return pcVar1;
}



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

undefined4 FUN_00042cb0(void)

{
  char *pcVar1;
  undefined4 uVar2;
  int iVar3;
  char *pcVar4;
  
  if (DAT_000df340 == (char *)0x0) {
    uVar2 = 0;
  }
  else {
    pcVar1 = DAT_000df340 + DAT_000df33c;
    if (DAT_000df340 < pcVar1) {
      pcVar4 = DAT_000df340;
      if (*DAT_000df340 == DAT_000df338) {
        iVar3 = 0;
      }
      else {
        do {
          pcVar4 = pcVar4 + 1;
          if (pcVar1 == pcVar4) goto LAB_00042cfb;
        } while (*pcVar4 != DAT_000df338);
        iVar3 = (int)pcVar4 - (int)DAT_000df340;
      }
      uVar2 = FUN_00073af0(DAT_000df340,iVar3);
      DAT_000df340 = pcVar4 + 1;
      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);
      return uVar2;
    }
LAB_00042cfb:
    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);
    DAT_000df340 = (char *)0x0;
    DAT_000df33c = 0;
  }
  return uVar2;
}


PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00016f80
ADD EBX,0x9a02c
MOV EAX,dword ptr [EBX + 0x265c]
TEST EAX,EAX
JZ 0x00042d54
MOV ECX,dword ptr [EBX + 0x2658]
LEA EDI,[EAX + ECX*0x1]
CMP EAX,EDI
JNC 0x00042cfb
MOVZX EDX,byte ptr [EBX + 0x2654]
MOV ESI,EAX
CMP byte ptr [EAX],DL
JNZ 0x00042cf4
JMP 0x00042d50
CMP byte ptr [ESI],DL
JZ 0x00042d20
ADD ESI,0x1
CMP EDI,ESI
JNZ 0x00042cf0
SUB ESP,0x8
PUSH ECX
PUSH EAX
CALL 0x00073af0
MOV dword ptr [EBX + 0x265c],0x0
MOV dword ptr [EBX + 0x2658],0x0
ADD ESP,0x10
POP EBX
POP ESI
POP EDI
RET
MOV EDX,ESI
SUB EDX,EAX
SUB ESP,0x8
ADD ESI,0x1
PUSH EDX
PUSH EAX
SUB EDI,ESI
CALL 0x00073af0
ADD ESP,0x10
MOV dword ptr [EBX + 0x265c],ESI
MOV dword ptr [EBX + 0x2658],EDI
POP EBX
POP ESI
POP EDI
RET
XOR EDX,EDX
JMP 0x00042d24
XOR EAX,EAX
JMP 0x00042d1c
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 FUN_00042cb0(void)\n\n{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}\n\n" comment (function_definition "undefined4 FUN_00042cb0(void)\n\n{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}" type_identifier (function_declarator "FUN_00042cb0(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}" { (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (if_statement "if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" if (parenthesized_expression "(DAT_000df340 == (char *)0x0)" ( (binary_expression "DAT_000df340 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar2 = 0;\n  }" { (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" else (compound_statement "{\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" { (expression_statement "pcVar1 = DAT_000df340 + DAT_000df33c;" (assignment_expression "pcVar1 = DAT_000df340 + DAT_000df33c" identifier = (binary_expression "DAT_000df340 + DAT_000df33c" identifier + identifier)) ;) (if_statement "if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }" if (parenthesized_expression "(DAT_000df340 < pcVar1)" ( (binary_expression "DAT_000df340 < pcVar1" identifier < identifier) )) (compound_statement "{\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }" { (expression_statement "pcVar4 = DAT_000df340;" (assignment_expression "pcVar4 = DAT_000df340" identifier = identifier) ;) (if_statement "if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" if (parenthesized_expression "(*DAT_000df340 == DAT_000df338)" ( (binary_expression "*DAT_000df340 == DAT_000df338" (pointer_expression "*DAT_000df340" * identifier) == identifier) )) (compound_statement "{\n        iVar3 = 0;\n      }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" else (compound_statement "{\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" { (do_statement "do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);" do (compound_statement "{\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        }" { (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) (if_statement "if (pcVar1 == pcVar4) goto LAB_00042cfb;" if (parenthesized_expression "(pcVar1 == pcVar4)" ( (binary_expression "pcVar1 == pcVar4" identifier == identifier) )) (goto_statement "goto LAB_00042cfb;" goto statement_identifier ;)) }) while (parenthesized_expression "(*pcVar4 != DAT_000df338)" ( (binary_expression "*pcVar4 != DAT_000df338" (pointer_expression "*pcVar4" * identifier) != identifier) )) ;) (expression_statement "iVar3 = (int)pcVar4 - (int)DAT_000df340;" (assignment_expression "iVar3 = (int)pcVar4 - (int)DAT_000df340" identifier = (binary_expression "(int)pcVar4 - (int)DAT_000df340" (cast_expression "(int)pcVar4" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)DAT_000df340" ( (type_descriptor "int" primitive_type) ) identifier))) ;) }))) (expression_statement "uVar2 = FUN_00073af0(DAT_000df340,iVar3);" (assignment_expression "uVar2 = FUN_00073af0(DAT_000df340,iVar3)" identifier = (call_expression "FUN_00073af0(DAT_000df340,iVar3)" identifier (argument_list "(DAT_000df340,iVar3)" ( identifier , identifier )))) ;) (expression_statement "DAT_000df340 = pcVar4 + 1;" (assignment_expression "DAT_000df340 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) (expression_statement "DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);" (assignment_expression "DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1)" identifier = (binary_expression "(int)pcVar1 - (int)(pcVar4 + 1)" (cast_expression "(int)pcVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)(pcVar4 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar4 + 1)" ( (binary_expression "pcVar4 + 1" identifier + number_literal) ))))) ;) (return_statement "return uVar2;" return identifier ;) })) (labeled_statement "LAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);" statement_identifier : (expression_statement "uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);" (assignment_expression "uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c)" identifier = (call_expression "FUN_00073af0(DAT_000df340,DAT_000df33c)" identifier (argument_list "(DAT_000df340,DAT_000df33c)" ( identifier , identifier )))) ;)) (expression_statement "DAT_000df340 = (char *)0x0;" (assignment_expression "DAT_000df340 = (char *)0x0" identifier = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "DAT_000df33c = 0;" (assignment_expression "DAT_000df33c = 0" identifier = number_literal) ;) }))) (return_statement "return uVar2;" 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 * read_commands_string(char *prompt)\n\n{\n  char *pcVar1;\n  char *pcVar2;\n  size_t len;\n  char *pcVar3;\n  \n  if (commands_string == (char *)0x0) {\n    pcVar1 = (char *)0x0;\n  }\n  else {\n    pcVar1 = commands_string + commands_string_len;\n    if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }\nLAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);\n    commands_string = (char *)0x0;\n    commands_string_len = 0;\n  }\n  return pcVar1;\n}\n\n" comment comment (function_definition "char * read_commands_string(char *prompt)\n\n{\n  char *pcVar1;\n  char *pcVar2;\n  size_t len;\n  char *pcVar3;\n  \n  if (commands_string == (char *)0x0) {\n    pcVar1 = (char *)0x0;\n  }\n  else {\n    pcVar1 = commands_string + commands_string_len;\n    if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }\nLAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);\n    commands_string = (char *)0x0;\n    commands_string_len = 0;\n  }\n  return pcVar1;\n}" primitive_type (pointer_declarator "* read_commands_string(char *prompt)" * (function_declarator "read_commands_string(char *prompt)" identifier (parameter_list "(char *prompt)" ( (parameter_declaration "char *prompt" primitive_type (pointer_declarator "*prompt" * identifier)) )))) (compound_statement "{\n  char *pcVar1;\n  char *pcVar2;\n  size_t len;\n  char *pcVar3;\n  \n  if (commands_string == (char *)0x0) {\n    pcVar1 = (char *)0x0;\n  }\n  else {\n    pcVar1 = commands_string + commands_string_len;\n    if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }\nLAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);\n    commands_string = (char *)0x0;\n    commands_string_len = 0;\n  }\n  return pcVar1;\n}" { (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (declaration "size_t len;" primitive_type identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (if_statement "if (commands_string == (char *)0x0) {\n    pcVar1 = (char *)0x0;\n  }\n  else {\n    pcVar1 = commands_string + commands_string_len;\n    if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }\nLAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);\n    commands_string = (char *)0x0;\n    commands_string_len = 0;\n  }" if (parenthesized_expression "(commands_string == (char *)0x0)" ( (binary_expression "commands_string == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    pcVar1 = (char *)0x0;\n  }" { (expression_statement "pcVar1 = (char *)0x0;" (assignment_expression "pcVar1 = (char *)0x0" identifier = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) }) (else_clause "else {\n    pcVar1 = commands_string + commands_string_len;\n    if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }\nLAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);\n    commands_string = (char *)0x0;\n    commands_string_len = 0;\n  }" else (compound_statement "{\n    pcVar1 = commands_string + commands_string_len;\n    if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }\nLAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);\n    commands_string = (char *)0x0;\n    commands_string_len = 0;\n  }" { (expression_statement "pcVar1 = commands_string + commands_string_len;" (assignment_expression "pcVar1 = commands_string + commands_string_len" identifier = (binary_expression "commands_string + commands_string_len" identifier + identifier)) ;) (if_statement "if (commands_string < pcVar1) {\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }" if (parenthesized_expression "(commands_string < pcVar1)" ( (binary_expression "commands_string < pcVar1" identifier < identifier) )) (compound_statement "{\n      pcVar3 = commands_string;\n      if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }\n      pcVar2 = estrdup(commands_string,len);\n      commands_string = pcVar3 + 1;\n      commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);\n      return pcVar2;\n    }" { (expression_statement "pcVar3 = commands_string;" (assignment_expression "pcVar3 = commands_string" identifier = identifier) ;) (if_statement "if (*commands_string == line_sep) {\n        len = 0;\n      }\n      else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }" if (parenthesized_expression "(*commands_string == line_sep)" ( (binary_expression "*commands_string == line_sep" (pointer_expression "*commands_string" * identifier) == identifier) )) (compound_statement "{\n        len = 0;\n      }" { (expression_statement "len = 0;" (assignment_expression "len = 0" identifier = number_literal) ;) }) (else_clause "else {\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }" else (compound_statement "{\n        do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);\n        len = (int)pcVar3 - (int)commands_string;\n      }" { (do_statement "do {\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        } while (*pcVar3 != line_sep);" do (compound_statement "{\n          pcVar3 = pcVar3 + 1;\n          if (pcVar1 == pcVar3) goto LAB_00042cfb;\n        }" { (expression_statement "pcVar3 = pcVar3 + 1;" (assignment_expression "pcVar3 = pcVar3 + 1" identifier = (binary_expression "pcVar3 + 1" identifier + number_literal)) ;) (if_statement "if (pcVar1 == pcVar3) goto LAB_00042cfb;" if (parenthesized_expression "(pcVar1 == pcVar3)" ( (binary_expression "pcVar1 == pcVar3" identifier == identifier) )) (goto_statement "goto LAB_00042cfb;" goto statement_identifier ;)) }) while (parenthesized_expression "(*pcVar3 != line_sep)" ( (binary_expression "*pcVar3 != line_sep" (pointer_expression "*pcVar3" * identifier) != identifier) )) ;) (expression_statement "len = (int)pcVar3 - (int)commands_string;" (assignment_expression "len = (int)pcVar3 - (int)commands_string" identifier = (binary_expression "(int)pcVar3 - (int)commands_string" (cast_expression "(int)pcVar3" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)commands_string" ( (type_descriptor "int" primitive_type) ) identifier))) ;) }))) (expression_statement "pcVar2 = estrdup(commands_string,len);" (assignment_expression "pcVar2 = estrdup(commands_string,len)" identifier = (call_expression "estrdup(commands_string,len)" identifier (argument_list "(commands_string,len)" ( identifier , identifier )))) ;) (expression_statement "commands_string = pcVar3 + 1;" (assignment_expression "commands_string = pcVar3 + 1" identifier = (binary_expression "pcVar3 + 1" identifier + number_literal)) ;) (expression_statement "commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1);" (assignment_expression "commands_string_len = (int)pcVar1 - (int)(pcVar3 + 1)" identifier = (binary_expression "(int)pcVar1 - (int)(pcVar3 + 1)" (cast_expression "(int)pcVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)(pcVar3 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar3 + 1)" ( (binary_expression "pcVar3 + 1" identifier + number_literal) ))))) ;) (return_statement "return pcVar2;" return identifier ;) })) (labeled_statement "LAB_00042cfb:\n    pcVar1 = estrdup(commands_string,commands_string_len);" statement_identifier : (expression_statement "pcVar1 = estrdup(commands_string,commands_string_len);" (assignment_expression "pcVar1 = estrdup(commands_string,commands_string_len)" identifier = (call_expression "estrdup(commands_string,commands_string_len)" identifier (argument_list "(commands_string,commands_string_len)" ( identifier , identifier )))) ;)) (expression_statement "commands_string = (char *)0x0;" (assignment_expression "commands_string = (char *)0x0" identifier = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "commands_string_len = 0;" (assignment_expression "commands_string_len = 0" identifier = number_literal) ;) }))) (return_statement "return pcVar1;" return identifier ;) })))
(translation_unit "undefined4 FUN_00042cb0(void)\n\n{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}\n\n" (function_definition "undefined4 FUN_00042cb0(void)\n\n{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}" type_identifier (function_declarator "FUN_00042cb0(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}" { (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (if_statement "if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" if (parenthesized_expression "(DAT_000df340 == (char *)0x0)" ( (binary_expression "DAT_000df340 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar2 = 0;\n  }" { (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" else (compound_statement "{\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" { (expression_statement "pcVar1 = DAT_000df340 + DAT_000df33c;" (assignment_expression "pcVar1 = DAT_000df340 + DAT_000df33c" identifier = (binary_expression "DAT_000df340 + DAT_000df33c" identifier + identifier)) ;) (if_statement "if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }" if (parenthesized_expression "(DAT_000df340 < pcVar1)" ( (binary_expression "DAT_000df340 < pcVar1" identifier < identifier) )) (compound_statement "{\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }" { (expression_statement "pcVar4 = DAT_000df340;" (assignment_expression "pcVar4 = DAT_000df340" identifier = identifier) ;) (if_statement "if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" if (parenthesized_expression "(*DAT_000df340 == DAT_000df338)" ( (binary_expression "*DAT_000df340 == DAT_000df338" (pointer_expression "*DAT_000df340" * identifier) == identifier) )) (compound_statement "{\n        iVar3 = 0;\n      }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) }) (else_clause "else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" else (compound_statement "{\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" { (do_statement "do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);" do (compound_statement "{\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        }" { (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) (if_statement "if (pcVar1 == pcVar4) goto LAB_00042cfb;" if (parenthesized_expression "(pcVar1 == pcVar4)" ( (binary_expression "pcVar1 == pcVar4" identifier == identifier) )) (goto_statement "goto LAB_00042cfb;" goto statement_identifier ;)) }) while (parenthesized_expression "(*pcVar4 != DAT_000df338)" ( (binary_expression "*pcVar4 != DAT_000df338" (pointer_expression "*pcVar4" * identifier) != identifier) )) ;) (expression_statement "iVar3 = (int)pcVar4 - (int)DAT_000df340;" (assignment_expression "iVar3 = (int)pcVar4 - (int)DAT_000df340" identifier = (binary_expression "(int)pcVar4 - (int)DAT_000df340" (cast_expression "(int)pcVar4" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)DAT_000df340" ( (type_descriptor "int" primitive_type) ) identifier))) ;) }))) (expression_statement "uVar2 = FUN_00073af0(DAT_000df340,iVar3);" (assignment_expression "uVar2 = FUN_00073af0(DAT_000df340,iVar3)" identifier = (call_expression "FUN_00073af0(DAT_000df340,iVar3)" identifier (argument_list "(DAT_000df340,iVar3)" ( identifier , identifier )))) ;) (expression_statement "DAT_000df340 = pcVar4 + 1;" (assignment_expression "DAT_000df340 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) (expression_statement "DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);" (assignment_expression "DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1)" identifier = (binary_expression "(int)pcVar1 - (int)(pcVar4 + 1)" (cast_expression "(int)pcVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)(pcVar4 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar4 + 1)" ( (binary_expression "pcVar4 + 1" identifier + number_literal) ))))) ;) (return_statement "return uVar2;" return identifier ;) })) (labeled_statement "LAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);" statement_identifier : (expression_statement "uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);" (assignment_expression "uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c)" identifier = (call_expression "FUN_00073af0(DAT_000df340,DAT_000df33c)" identifier (argument_list "(DAT_000df340,DAT_000df33c)" ( identifier , identifier )))) ;)) (expression_statement "DAT_000df340 = (char *)0x0;" (assignment_expression "DAT_000df340 = (char *)0x0" identifier = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "DAT_000df33c = 0;" (assignment_expression "DAT_000df33c = 0" identifier = number_literal) ;) }))) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE 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 = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == IDENT) )) (goto_statement goto statement_identifier ;)) }) while (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != IDENT) )) ;) (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) }))) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (return_statement return IDENT ;) })) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;)) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }))) (return_statement return IDENT ;) })))
(function_definition "undefined4 FUN_00042cb0(void)\n\n{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}" (type_identifier "undefined4") (function_declarator "FUN_00042cb0(void)" (identifier "FUN_00042cb0") (parameter_list "(void)" (( "(") (parameter_declaration "void" (primitive_type "void")) () ")"))) (compound_statement "{\n  char *pcVar1;\n  undefined4 uVar2;\n  int iVar3;\n  char *pcVar4;\n  \n  if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }\n  return uVar2;\n}" ({ "{") (declaration "char *pcVar1;" (primitive_type "char") (pointer_declarator "*pcVar1" (* "*") (identifier "pcVar1")) (; ";")) (declaration "undefined4 uVar2;" (type_identifier "undefined4") (identifier "uVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "char *pcVar4;" (primitive_type "char") (pointer_declarator "*pcVar4" (* "*") (identifier "pcVar4")) (; ";")) (if_statement "if (DAT_000df340 == (char *)0x0) {\n    uVar2 = 0;\n  }\n  else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" (if "if") (parenthesized_expression "(DAT_000df340 == (char *)0x0)" (( "(") (binary_expression "DAT_000df340 == (char *)0x0" (identifier "DAT_000df340") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    uVar2 = 0;\n  }" ({ "{") (expression_statement "uVar2 = 0;" (assignment_expression "uVar2 = 0" (identifier "uVar2") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" (else "else") (compound_statement "{\n    pcVar1 = DAT_000df340 + DAT_000df33c;\n    if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }\nLAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);\n    DAT_000df340 = (char *)0x0;\n    DAT_000df33c = 0;\n  }" ({ "{") (expression_statement "pcVar1 = DAT_000df340 + DAT_000df33c;" (assignment_expression "pcVar1 = DAT_000df340 + DAT_000df33c" (identifier "pcVar1") (= "=") (binary_expression "DAT_000df340 + DAT_000df33c" (identifier "DAT_000df340") (+ "+") (identifier "DAT_000df33c"))) (; ";")) (if_statement "if (DAT_000df340 < pcVar1) {\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }" (if "if") (parenthesized_expression "(DAT_000df340 < pcVar1)" (( "(") (binary_expression "DAT_000df340 < pcVar1" (identifier "DAT_000df340") (< "<") (identifier "pcVar1")) () ")")) (compound_statement "{\n      pcVar4 = DAT_000df340;\n      if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }\n      uVar2 = FUN_00073af0(DAT_000df340,iVar3);\n      DAT_000df340 = pcVar4 + 1;\n      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);\n      return uVar2;\n    }" ({ "{") (expression_statement "pcVar4 = DAT_000df340;" (assignment_expression "pcVar4 = DAT_000df340" (identifier "pcVar4") (= "=") (identifier "DAT_000df340")) (; ";")) (if_statement "if (*DAT_000df340 == DAT_000df338) {\n        iVar3 = 0;\n      }\n      else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" (if "if") (parenthesized_expression "(*DAT_000df340 == DAT_000df338)" (( "(") (binary_expression "*DAT_000df340 == DAT_000df338" (pointer_expression "*DAT_000df340" (* "*") (identifier "DAT_000df340")) (== "==") (identifier "DAT_000df338")) () ")")) (compound_statement "{\n        iVar3 = 0;\n      }" ({ "{") (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" (identifier "iVar3") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" (else "else") (compound_statement "{\n        do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);\n        iVar3 = (int)pcVar4 - (int)DAT_000df340;\n      }" ({ "{") (do_statement "do {\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        } while (*pcVar4 != DAT_000df338);" (do "do") (compound_statement "{\n          pcVar4 = pcVar4 + 1;\n          if (pcVar1 == pcVar4) goto LAB_00042cfb;\n        }" ({ "{") (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" (identifier "pcVar4") (= "=") (binary_expression "pcVar4 + 1" (identifier "pcVar4") (+ "+") (number_literal "1"))) (; ";")) (if_statement "if (pcVar1 == pcVar4) goto LAB_00042cfb;" (if "if") (parenthesized_expression "(pcVar1 == pcVar4)" (( "(") (binary_expression "pcVar1 == pcVar4" (identifier "pcVar1") (== "==") (identifier "pcVar4")) () ")")) (goto_statement "goto LAB_00042cfb;" (goto "goto") (statement_identifier "LAB_00042cfb") (; ";"))) (} "}")) (while "while") (parenthesized_expression "(*pcVar4 != DAT_000df338)" (( "(") (binary_expression "*pcVar4 != DAT_000df338" (pointer_expression "*pcVar4" (* "*") (identifier "pcVar4")) (!= "!=") (identifier "DAT_000df338")) () ")")) (; ";")) (expression_statement "iVar3 = (int)pcVar4 - (int)DAT_000df340;" (assignment_expression "iVar3 = (int)pcVar4 - (int)DAT_000df340" (identifier "iVar3") (= "=") (binary_expression "(int)pcVar4 - (int)DAT_000df340" (cast_expression "(int)pcVar4" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pcVar4")) (- "-") (cast_expression "(int)DAT_000df340" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "DAT_000df340")))) (; ";")) (} "}")))) (expression_statement "uVar2 = FUN_00073af0(DAT_000df340,iVar3);" (assignment_expression "uVar2 = FUN_00073af0(DAT_000df340,iVar3)" (identifier "uVar2") (= "=") (call_expression "FUN_00073af0(DAT_000df340,iVar3)" (identifier "FUN_00073af0") (argument_list "(DAT_000df340,iVar3)" (( "(") (identifier "DAT_000df340") (, ",") (identifier "iVar3") () ")")))) (; ";")) (expression_statement "DAT_000df340 = pcVar4 + 1;" (assignment_expression "DAT_000df340 = pcVar4 + 1" (identifier "DAT_000df340") (= "=") (binary_expression "pcVar4 + 1" (identifier "pcVar4") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);" (assignment_expression "DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1)" (identifier "DAT_000df33c") (= "=") (binary_expression "(int)pcVar1 - (int)(pcVar4 + 1)" (cast_expression "(int)pcVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pcVar1")) (- "-") (cast_expression "(int)(pcVar4 + 1)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(pcVar4 + 1)" (( "(") (binary_expression "pcVar4 + 1" (identifier "pcVar4") (+ "+") (number_literal "1")) () ")"))))) (; ";")) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}"))) (labeled_statement "LAB_00042cfb:\n    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);" (statement_identifier "LAB_00042cfb") (: ":") (expression_statement "uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);" (assignment_expression "uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c)" (identifier "uVar2") (= "=") (call_expression "FUN_00073af0(DAT_000df340,DAT_000df33c)" (identifier "FUN_00073af0") (argument_list "(DAT_000df340,DAT_000df33c)" (( "(") (identifier "DAT_000df340") (, ",") (identifier "DAT_000df33c") () ")")))) (; ";"))) (expression_statement "DAT_000df340 = (char *)0x0;" (assignment_expression "DAT_000df340 = (char *)0x0" (identifier "DAT_000df340") (= "=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "DAT_000df33c = 0;" (assignment_expression "DAT_000df33c = 0" (identifier "DAT_000df33c") (= "=") (number_literal "0")) (; ";")) (} "}")))) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}")))

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

char * function_1(char *prompt)

{
  char *var_3;
  char *pcVar2;
  size_t len;
  char *var_5;
  
  if (var_1 == (char *)0x0) {
    var_3 = (char *)0x0;
  }
  else {
    var_3 = var_1 + var_2;
    if (var_1 < var_3) {
      var_5 = var_1;
      if (*var_1 == var_4) {
        len = 0;
      }
      else {
        do {
          var_5 = var_5 + 1;
          if (var_3 == var_5) goto LAB_00042cfb;
        } while (*var_5 != var_4);
        len = (int)var_5 - (int)var_1;
      }
      pcVar2 = var_6(var_1,len);
      var_1 = var_5 + 1;
      var_2 = (int)var_3 - (int)(var_5 + 1);
      return pcVar2;
    }
LAB_00042cfb:
    var_3 = var_6(var_1,var_2);
    var_1 = (char *)0x0;
    var_2 = 0;
  }
  return var_3;
}


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

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

undefined4 MASKED(void)

{
  char *pcVar1;
  undefined4 uVar2;
  int iVar3;
  char *pcVar4;
  
  if (DAT_000df340 == (char *)0x0) {
    uVar2 = 0;
  }
  else {
    pcVar1 = DAT_000df340 + DAT_000df33c;
    if (DAT_000df340 < pcVar1) {
      pcVar4 = DAT_000df340;
      if (*DAT_000df340 == DAT_000df338) {
        iVar3 = 0;
      }
      else {
        do {
          pcVar4 = pcVar4 + 1;
          if (pcVar1 == pcVar4) goto LAB_00042cfb;
        } while (*pcVar4 != DAT_000df338);
        iVar3 = (int)pcVar4 - (int)DAT_000df340;
      }
      uVar2 = FUN_00073af0(DAT_000df340,iVar3);
      DAT_000df340 = pcVar4 + 1;
      DAT_000df33c = (int)pcVar1 - (int)(pcVar4 + 1);
      return uVar2;
    }
LAB_00042cfb:
    uVar2 = FUN_00073af0(DAT_000df340,DAT_000df33c);
    DAT_000df340 = (char *)0x0;
    DAT_000df33c = 0;
  }
  return uVar2;
}

