
/* WARNING: Enum "anon_enum_32": Some values do not have unique names */

void activate_option(Telnet telnet,Opt *o)

{
  Telnet telnet_00;
  int iVar1;
  int iVar2;
  int *piVar3;
  Opt *o_00;
  Telnet unaff_EBX;
  int unaff_ESI;
  int unaff_EDI;
  undefined8 uVar4;
  int option;
  
  option = unaff_EDI;
  uVar4 = __x86_get_pc_thunk_di();
  piVar3 = (int *)((ulonglong)uVar4 >> 0x20);
  telnet_00 = (Telnet)uVar4;
  o_00 = (Opt *)*piVar3;
  iVar2 = piVar3[4];
  if (o_00 == (Opt *)0xfb) {
    if (iVar2 == 0x1f) {
      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);
      o_00 = (Opt *)*piVar3;
      iVar2 = piVar3[4];
      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;
    }
    if ((iVar2 == 0x27) || (iVar2 == 0x24)) {
      if (iVar2 == 0x27) {
        iVar1 = 3;
        iVar2 = unaff_EDI + 0x5815e;
      }
      else {
        iVar1 = 4;
        iVar2 = unaff_EDI + 0x58142;
      }
      if ((uint)telnet_00->opt_states[iVar1] < 2) {
        send_opt(unaff_EBX,unaff_ESI,option);
        iVar1 = *(int *)(iVar2 + 0x14);
      }
      telnet_00->opt_states[iVar1] = 3;
      o_00 = (Opt *)*piVar3;
      iVar2 = piVar3[4];
    }
    else {
      o_00 = (Opt *)*piVar3;
    }
  }
LAB_0007167f:
  option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1);
  return;
}



void FUN_00071660(void)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int *piVar4;
  int unaff_EDI;
  undefined8 uVar5;
  
  uVar5 = FUN_0004e9eb();
  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);
  iVar1 = (int)uVar5;
  iVar3 = piVar4[4];
  if (*piVar4 == 0xfb) {
    if (iVar3 == 0x1f) {
      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));
      iVar3 = piVar4[4];
      if (*piVar4 != 0xfb) goto LAB_0007167f;
    }
    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {
      if (iVar3 == 0x27) {
        iVar2 = 3;
        iVar3 = unaff_EDI + 0x5815e;
      }
      else {
        iVar2 = 4;
        iVar3 = unaff_EDI + 0x58142;
      }
      iVar2 = iVar2 + 4;
      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {
        FUN_00071060();
        iVar2 = *(int *)(iVar3 + 0x14) + 4;
      }
      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;
    }
  }
LAB_0007167f:
  FUN_00071570(1);
  return;
}


PUSH EDI
CALL 0x0004e9eb
ADD EDI,0x9f0ea
PUSH ESI
MOV ESI,EAX
PUSH EBX
MOV EBX,EDX
MOV EDX,dword ptr [EDX]
MOV ECX,dword ptr [EBX + 0x10]
CMP EDX,0xfb
JZ 0x00071698
SUB ESP,0xc
MOV EAX,ESI
PUSH 0x1
CALL 0x00071570
ADD ESP,0x10
POP EBX
POP ESI
POP EDI
RET
CMP ECX,0x1f
JZ 0x000716e0
CMP ECX,0x27
JZ 0x000716b0
CMP ECX,0x24
JZ 0x000716b0
MOV EDX,dword ptr [EBX]
JMP 0x0007167f
CMP ECX,0x27
JZ 0x00071708
MOV EAX,0x4
LEA EDI,[EDI + 0xfffb9058]
ADD EAX,0x4
CMP dword ptr [ESI + EAX*0x4 + 0xc],0x1
JBE 0x00071718
MOV dword ptr [ESI + EAX*0x4 + 0xc],0x3
MOV EDX,dword ptr [EBX]
MOV ECX,dword ptr [EBX + 0x10]
JMP 0x0007167f
SUB ESP,0x4
PUSH dword ptr [EAX + 0x18]
PUSH dword ptr [EAX + 0x14]
PUSH EAX
CALL 0x00070d90
MOV EDX,dword ptr [EBX]
ADD ESP,0x10
MOV ECX,dword ptr [EBX + 0x10]
CMP EDX,0xfb
JZ 0x0007169d
JMP 0x0007167f
MOV EAX,0x3
LEA EDI,[EDI + 0xfffb9074]
JMP 0x000716c0
MOV ECX,dword ptr [EDI + 0x10]
MOV EDX,dword ptr [EDI + 0x4]
MOV EAX,ESI
CALL 0x00071060
MOV EAX,dword ptr [EDI + 0x14]
ADD EAX,0x4
JMP 0x000716ca
(translation_unit "void FUN_00071660(void)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}\n\n" (function_definition "void FUN_00071660(void)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}" primitive_type (function_declarator "FUN_00071660(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "int unaff_EDI;" primitive_type identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (expression_statement "uVar5 = FUN_0004e9eb();" (assignment_expression "uVar5 = FUN_0004e9eb()" identifier = (call_expression "FUN_0004e9eb()" identifier (argument_list "()" ( )))) ;) (expression_statement "piVar4 = (int *)((ulonglong)uVar5 >> 0x20);" (assignment_expression "piVar4 = (int *)((ulonglong)uVar5 >> 0x20)" identifier = (cast_expression "(int *)((ulonglong)uVar5 >> 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" ( (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" ( (type_descriptor "ulonglong" type_identifier) ) identifier) >> number_literal) )))) ;) (expression_statement "iVar1 = (int)uVar5;" (assignment_expression "iVar1 = (int)uVar5" identifier = (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "iVar3 = piVar4[4];" (assignment_expression "iVar3 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (if_statement "if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }" if (parenthesized_expression "(*piVar4 == 0xfb)" ( (binary_expression "*piVar4 == 0xfb" (pointer_expression "*piVar4" * identifier) == number_literal) )) (compound_statement "{\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }" { (if_statement "if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }" if (parenthesized_expression "(iVar3 == 0x1f)" ( (binary_expression "iVar3 == 0x1f" identifier == number_literal) )) (compound_statement "{\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }" { (expression_statement "FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));" (call_expression "FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18))" identifier (argument_list "(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18))" ( identifier , (pointer_expression "*(undefined4 *)(iVar1 + 0x14)" * (cast_expression "(undefined4 *)(iVar1 + 0x14)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x14)" ( (binary_expression "iVar1 + 0x14" identifier + number_literal) )))) , (pointer_expression "*(undefined4 *)(iVar1 + 0x18)" * (cast_expression "(undefined4 *)(iVar1 + 0x18)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x18)" ( (binary_expression "iVar1 + 0x18" identifier + number_literal) )))) ))) ;) (expression_statement "iVar3 = piVar4[4];" (assignment_expression "iVar3 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (if_statement "if (*piVar4 != 0xfb) goto LAB_0007167f;" if (parenthesized_expression "(*piVar4 != 0xfb)" ( (binary_expression "*piVar4 != 0xfb" (pointer_expression "*piVar4" * identifier) != number_literal) )) (goto_statement "goto LAB_0007167f;" goto statement_identifier ;)) })) (if_statement "if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }" if (parenthesized_expression "((iVar3 == 0x27) || (iVar3 == 0x24))" ( (binary_expression "(iVar3 == 0x27) || (iVar3 == 0x24)" (parenthesized_expression "(iVar3 == 0x27)" ( (binary_expression "iVar3 == 0x27" identifier == number_literal) )) || (parenthesized_expression "(iVar3 == 0x24)" ( (binary_expression "iVar3 == 0x24" identifier == number_literal) ))) )) (compound_statement "{\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }" { (if_statement "if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" if (parenthesized_expression "(iVar3 == 0x27)" ( (binary_expression "iVar3 == 0x27" identifier == number_literal) )) (compound_statement "{\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }" { (expression_statement "iVar2 = 3;" (assignment_expression "iVar2 = 3" identifier = number_literal) ;) (expression_statement "iVar3 = unaff_EDI + 0x5815e;" (assignment_expression "iVar3 = unaff_EDI + 0x5815e" identifier = (binary_expression "unaff_EDI + 0x5815e" identifier + number_literal)) ;) }) (else_clause "else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" else (compound_statement "{\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" { (expression_statement "iVar2 = 4;" (assignment_expression "iVar2 = 4" identifier = number_literal) ;) (expression_statement "iVar3 = unaff_EDI + 0x58142;" (assignment_expression "iVar3 = unaff_EDI + 0x58142" identifier = (binary_expression "unaff_EDI + 0x58142" identifier + number_literal)) ;) }))) (expression_statement "iVar2 = iVar2 + 4;" (assignment_expression "iVar2 = iVar2 + 4" identifier = (binary_expression "iVar2 + 4" identifier + number_literal)) ;) (if_statement "if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }" if (parenthesized_expression "(*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2)" ( (binary_expression "*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2" (pointer_expression "*(uint *)(iVar1 + 0xc + iVar2 * 4)" * (cast_expression "(uint *)(iVar1 + 0xc + iVar2 * 4)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0xc + iVar2 * 4)" ( (binary_expression "iVar1 + 0xc + iVar2 * 4" (binary_expression "iVar1 + 0xc" identifier + number_literal) + (binary_expression "iVar2 * 4" identifier * number_literal)) )))) < number_literal) )) (compound_statement "{\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }" { (expression_statement "FUN_00071060();" (call_expression "FUN_00071060()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = *(int *)(iVar3 + 0x14) + 4;" (assignment_expression "iVar2 = *(int *)(iVar3 + 0x14) + 4" identifier = (binary_expression "*(int *)(iVar3 + 0x14) + 4" (pointer_expression "*(int *)(iVar3 + 0x14)" * (cast_expression "(int *)(iVar3 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + 0x14)" ( (binary_expression "iVar3 + 0x14" identifier + number_literal) )))) + number_literal)) ;) })) (expression_statement "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;" (assignment_expression "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3" (pointer_expression "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4)" * (cast_expression "(undefined4 *)(iVar1 + 0xc + iVar2 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0xc + iVar2 * 4)" ( (binary_expression "iVar1 + 0xc + iVar2 * 4" (binary_expression "iVar1 + 0xc" identifier + number_literal) + (binary_expression "iVar2 * 4" identifier * number_literal)) )))) = number_literal) ;) })) })) (labeled_statement "LAB_0007167f:\n  FUN_00071570(1);" statement_identifier : (expression_statement "FUN_00071570(1);" (call_expression "FUN_00071570(1)" identifier (argument_list "(1)" ( number_literal ))) ;)) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Enum "anon_enum_32": Some values do not have unique names */\n\nvoid activate_option(Telnet telnet,Opt *o)\n\n{\n  Telnet telnet_00;\n  int iVar1;\n  int iVar2;\n  int *piVar3;\n  Opt *o_00;\n  Telnet unaff_EBX;\n  int unaff_ESI;\n  int unaff_EDI;\n  undefined8 uVar4;\n  int option;\n  \n  option = unaff_EDI;\n  uVar4 = __x86_get_pc_thunk_di();\n  piVar3 = (int *)((ulonglong)uVar4 >> 0x20);\n  telnet_00 = (Telnet)uVar4;\n  o_00 = (Opt *)*piVar3;\n  iVar2 = piVar3[4];\n  if (o_00 == (Opt *)0xfb) {\n    if (iVar2 == 0x1f) {\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }\n    if ((iVar2 == 0x27) || (iVar2 == 0x24)) {\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }\n    else {\n      o_00 = (Opt *)*piVar3;\n    }\n  }\nLAB_0007167f:\n  option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1);\n  return;\n}\n\n" comment (function_definition "void activate_option(Telnet telnet,Opt *o)\n\n{\n  Telnet telnet_00;\n  int iVar1;\n  int iVar2;\n  int *piVar3;\n  Opt *o_00;\n  Telnet unaff_EBX;\n  int unaff_ESI;\n  int unaff_EDI;\n  undefined8 uVar4;\n  int option;\n  \n  option = unaff_EDI;\n  uVar4 = __x86_get_pc_thunk_di();\n  piVar3 = (int *)((ulonglong)uVar4 >> 0x20);\n  telnet_00 = (Telnet)uVar4;\n  o_00 = (Opt *)*piVar3;\n  iVar2 = piVar3[4];\n  if (o_00 == (Opt *)0xfb) {\n    if (iVar2 == 0x1f) {\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }\n    if ((iVar2 == 0x27) || (iVar2 == 0x24)) {\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }\n    else {\n      o_00 = (Opt *)*piVar3;\n    }\n  }\nLAB_0007167f:\n  option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1);\n  return;\n}" primitive_type (function_declarator "activate_option(Telnet telnet,Opt *o)" identifier (parameter_list "(Telnet telnet,Opt *o)" ( (parameter_declaration "Telnet telnet" type_identifier identifier) , (parameter_declaration "Opt *o" type_identifier (pointer_declarator "*o" * identifier)) ))) (compound_statement "{\n  Telnet telnet_00;\n  int iVar1;\n  int iVar2;\n  int *piVar3;\n  Opt *o_00;\n  Telnet unaff_EBX;\n  int unaff_ESI;\n  int unaff_EDI;\n  undefined8 uVar4;\n  int option;\n  \n  option = unaff_EDI;\n  uVar4 = __x86_get_pc_thunk_di();\n  piVar3 = (int *)((ulonglong)uVar4 >> 0x20);\n  telnet_00 = (Telnet)uVar4;\n  o_00 = (Opt *)*piVar3;\n  iVar2 = piVar3[4];\n  if (o_00 == (Opt *)0xfb) {\n    if (iVar2 == 0x1f) {\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }\n    if ((iVar2 == 0x27) || (iVar2 == 0x24)) {\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }\n    else {\n      o_00 = (Opt *)*piVar3;\n    }\n  }\nLAB_0007167f:\n  option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1);\n  return;\n}" { (declaration "Telnet telnet_00;" type_identifier identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int *piVar3;" primitive_type (pointer_declarator "*piVar3" * identifier) ;) (declaration "Opt *o_00;" type_identifier (pointer_declarator "*o_00" * identifier) ;) (declaration "Telnet unaff_EBX;" type_identifier identifier ;) (declaration "int unaff_ESI;" primitive_type identifier ;) (declaration "int unaff_EDI;" primitive_type identifier ;) (declaration "undefined8 uVar4;" type_identifier identifier ;) (declaration "int option;" primitive_type identifier ;) (expression_statement "option = unaff_EDI;" (assignment_expression "option = unaff_EDI" identifier = identifier) ;) (expression_statement "uVar4 = __x86_get_pc_thunk_di();" (assignment_expression "uVar4 = __x86_get_pc_thunk_di()" identifier = (call_expression "__x86_get_pc_thunk_di()" identifier (argument_list "()" ( )))) ;) (expression_statement "piVar3 = (int *)((ulonglong)uVar4 >> 0x20);" (assignment_expression "piVar3 = (int *)((ulonglong)uVar4 >> 0x20)" identifier = (cast_expression "(int *)((ulonglong)uVar4 >> 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulonglong)uVar4 >> 0x20)" ( (binary_expression "(ulonglong)uVar4 >> 0x20" (cast_expression "(ulonglong)uVar4" ( (type_descriptor "ulonglong" type_identifier) ) identifier) >> number_literal) )))) ;) (expression_statement "telnet_00 = (Telnet)uVar4;" (assignment_expression "telnet_00 = (Telnet)uVar4" identifier = (cast_expression "(Telnet)uVar4" ( (type_descriptor "Telnet" type_identifier) ) identifier)) ;) (expression_statement "o_00 = (Opt *)*piVar3;" (assignment_expression "o_00 = (Opt *)*piVar3" identifier = (cast_expression "(Opt *)*piVar3" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "iVar2 = piVar3[4];" (assignment_expression "iVar2 = piVar3[4]" identifier = (subscript_expression "piVar3[4]" identifier [ number_literal ])) ;) (if_statement "if (o_00 == (Opt *)0xfb) {\n    if (iVar2 == 0x1f) {\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }\n    if ((iVar2 == 0x27) || (iVar2 == 0x24)) {\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }\n    else {\n      o_00 = (Opt *)*piVar3;\n    }\n  }" if (parenthesized_expression "(o_00 == (Opt *)0xfb)" ( (binary_expression "o_00 == (Opt *)0xfb" identifier == (cast_expression "(Opt *)0xfb" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if (iVar2 == 0x1f) {\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }\n    if ((iVar2 == 0x27) || (iVar2 == 0x24)) {\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }\n    else {\n      o_00 = (Opt *)*piVar3;\n    }\n  }" { (if_statement "if (iVar2 == 0x1f) {\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }" if (parenthesized_expression "(iVar2 == 0x1f)" ( (binary_expression "iVar2 == 0x1f" identifier == number_literal) )) (compound_statement "{\n      telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n      if (o_00 != (Opt *)0xfb) goto LAB_0007167f;\n    }" { (expression_statement "telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height);" (call_expression "telnet_size(telnet_00,telnet_00->term_width,telnet_00->term_height)" identifier (argument_list "(telnet_00,telnet_00->term_width,telnet_00->term_height)" ( identifier , (field_expression "telnet_00->term_width" identifier -> field_identifier) , (field_expression "telnet_00->term_height" identifier -> field_identifier) ))) ;) (expression_statement "o_00 = (Opt *)*piVar3;" (assignment_expression "o_00 = (Opt *)*piVar3" identifier = (cast_expression "(Opt *)*piVar3" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "iVar2 = piVar3[4];" (assignment_expression "iVar2 = piVar3[4]" identifier = (subscript_expression "piVar3[4]" identifier [ number_literal ])) ;) (if_statement "if (o_00 != (Opt *)0xfb) goto LAB_0007167f;" if (parenthesized_expression "(o_00 != (Opt *)0xfb)" ( (binary_expression "o_00 != (Opt *)0xfb" identifier != (cast_expression "(Opt *)0xfb" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_0007167f;" goto statement_identifier ;)) })) (if_statement "if ((iVar2 == 0x27) || (iVar2 == 0x24)) {\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }\n    else {\n      o_00 = (Opt *)*piVar3;\n    }" if (parenthesized_expression "((iVar2 == 0x27) || (iVar2 == 0x24))" ( (binary_expression "(iVar2 == 0x27) || (iVar2 == 0x24)" (parenthesized_expression "(iVar2 == 0x27)" ( (binary_expression "iVar2 == 0x27" identifier == number_literal) )) || (parenthesized_expression "(iVar2 == 0x24)" ( (binary_expression "iVar2 == 0x24" identifier == number_literal) ))) )) (compound_statement "{\n      if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }\n      if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }\n      telnet_00->opt_states[iVar1] = 3;\n      o_00 = (Opt *)*piVar3;\n      iVar2 = piVar3[4];\n    }" { (if_statement "if (iVar2 == 0x27) {\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }" if (parenthesized_expression "(iVar2 == 0x27)" ( (binary_expression "iVar2 == 0x27" identifier == number_literal) )) (compound_statement "{\n        iVar1 = 3;\n        iVar2 = unaff_EDI + 0x5815e;\n      }" { (expression_statement "iVar1 = 3;" (assignment_expression "iVar1 = 3" identifier = number_literal) ;) (expression_statement "iVar2 = unaff_EDI + 0x5815e;" (assignment_expression "iVar2 = unaff_EDI + 0x5815e" identifier = (binary_expression "unaff_EDI + 0x5815e" identifier + number_literal)) ;) }) (else_clause "else {\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }" else (compound_statement "{\n        iVar1 = 4;\n        iVar2 = unaff_EDI + 0x58142;\n      }" { (expression_statement "iVar1 = 4;" (assignment_expression "iVar1 = 4" identifier = number_literal) ;) (expression_statement "iVar2 = unaff_EDI + 0x58142;" (assignment_expression "iVar2 = unaff_EDI + 0x58142" identifier = (binary_expression "unaff_EDI + 0x58142" identifier + number_literal)) ;) }))) (if_statement "if ((uint)telnet_00->opt_states[iVar1] < 2) {\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }" if (parenthesized_expression "((uint)telnet_00->opt_states[iVar1] < 2)" ( (binary_expression "(uint)telnet_00->opt_states[iVar1] < 2" (cast_expression "(uint)telnet_00->opt_states[iVar1]" ( (type_descriptor "uint" type_identifier) ) (subscript_expression "telnet_00->opt_states[iVar1]" (field_expression "telnet_00->opt_states" identifier -> field_identifier) [ identifier ])) < number_literal) )) (compound_statement "{\n        send_opt(unaff_EBX,unaff_ESI,option);\n        iVar1 = *(int *)(iVar2 + 0x14);\n      }" { (expression_statement "send_opt(unaff_EBX,unaff_ESI,option);" (call_expression "send_opt(unaff_EBX,unaff_ESI,option)" identifier (argument_list "(unaff_EBX,unaff_ESI,option)" ( identifier , identifier , identifier ))) ;) (expression_statement "iVar1 = *(int *)(iVar2 + 0x14);" (assignment_expression "iVar1 = *(int *)(iVar2 + 0x14)" identifier = (pointer_expression "*(int *)(iVar2 + 0x14)" * (cast_expression "(int *)(iVar2 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar2 + 0x14)" ( (binary_expression "iVar2 + 0x14" identifier + number_literal) ))))) ;) })) (expression_statement "telnet_00->opt_states[iVar1] = 3;" (assignment_expression "telnet_00->opt_states[iVar1] = 3" (subscript_expression "telnet_00->opt_states[iVar1]" (field_expression "telnet_00->opt_states" identifier -> field_identifier) [ identifier ]) = number_literal) ;) (expression_statement "o_00 = (Opt *)*piVar3;" (assignment_expression "o_00 = (Opt *)*piVar3" identifier = (cast_expression "(Opt *)*piVar3" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) (expression_statement "iVar2 = piVar3[4];" (assignment_expression "iVar2 = piVar3[4]" identifier = (subscript_expression "piVar3[4]" identifier [ number_literal ])) ;) }) (else_clause "else {\n      o_00 = (Opt *)*piVar3;\n    }" else (compound_statement "{\n      o_00 = (Opt *)*piVar3;\n    }" { (expression_statement "o_00 = (Opt *)*piVar3;" (assignment_expression "o_00 = (Opt *)*piVar3" identifier = (cast_expression "(Opt *)*piVar3" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*piVar3" * identifier))) ;) }))) })) (labeled_statement "LAB_0007167f:\n  option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1);" statement_identifier : (expression_statement "option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1);" (call_expression "option_side_effects(telnet_00,o_00,iVar2,(Opt *)0x1)" identifier (argument_list "(telnet_00,o_00,iVar2,(Opt *)0x1)" ( identifier , identifier , identifier , (cast_expression "(Opt *)0x1" ( (type_descriptor "Opt *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ))) ;)) (return_statement "return;" return ;) })))
(translation_unit "void FUN_00071660(void)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}\n\n" (function_definition "void FUN_00071660(void)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}" primitive_type (function_declarator "FUN_00071660(void)" identifier (parameter_list "(void)" ( (parameter_declaration "void" primitive_type) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "int unaff_EDI;" primitive_type identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (expression_statement "uVar5 = FUN_0004e9eb();" (assignment_expression "uVar5 = FUN_0004e9eb()" identifier = (call_expression "FUN_0004e9eb()" identifier (argument_list "()" ( )))) ;) (expression_statement "piVar4 = (int *)((ulonglong)uVar5 >> 0x20);" (assignment_expression "piVar4 = (int *)((ulonglong)uVar5 >> 0x20)" identifier = (cast_expression "(int *)((ulonglong)uVar5 >> 0x20)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" ( (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" ( (type_descriptor "ulonglong" type_identifier) ) identifier) >> number_literal) )))) ;) (expression_statement "iVar1 = (int)uVar5;" (assignment_expression "iVar1 = (int)uVar5" identifier = (cast_expression "(int)uVar5" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "iVar3 = piVar4[4];" (assignment_expression "iVar3 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (if_statement "if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }" if (parenthesized_expression "(*piVar4 == 0xfb)" ( (binary_expression "*piVar4 == 0xfb" (pointer_expression "*piVar4" * identifier) == number_literal) )) (compound_statement "{\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }" { (if_statement "if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }" if (parenthesized_expression "(iVar3 == 0x1f)" ( (binary_expression "iVar3 == 0x1f" identifier == number_literal) )) (compound_statement "{\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }" { (expression_statement "FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));" (call_expression "FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18))" identifier (argument_list "(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18))" ( identifier , (pointer_expression "*(undefined4 *)(iVar1 + 0x14)" * (cast_expression "(undefined4 *)(iVar1 + 0x14)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x14)" ( (binary_expression "iVar1 + 0x14" identifier + number_literal) )))) , (pointer_expression "*(undefined4 *)(iVar1 + 0x18)" * (cast_expression "(undefined4 *)(iVar1 + 0x18)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x18)" ( (binary_expression "iVar1 + 0x18" identifier + number_literal) )))) ))) ;) (expression_statement "iVar3 = piVar4[4];" (assignment_expression "iVar3 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (if_statement "if (*piVar4 != 0xfb) goto LAB_0007167f;" if (parenthesized_expression "(*piVar4 != 0xfb)" ( (binary_expression "*piVar4 != 0xfb" (pointer_expression "*piVar4" * identifier) != number_literal) )) (goto_statement "goto LAB_0007167f;" goto statement_identifier ;)) })) (if_statement "if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }" if (parenthesized_expression "((iVar3 == 0x27) || (iVar3 == 0x24))" ( (binary_expression "(iVar3 == 0x27) || (iVar3 == 0x24)" (parenthesized_expression "(iVar3 == 0x27)" ( (binary_expression "iVar3 == 0x27" identifier == number_literal) )) || (parenthesized_expression "(iVar3 == 0x24)" ( (binary_expression "iVar3 == 0x24" identifier == number_literal) ))) )) (compound_statement "{\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }" { (if_statement "if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" if (parenthesized_expression "(iVar3 == 0x27)" ( (binary_expression "iVar3 == 0x27" identifier == number_literal) )) (compound_statement "{\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }" { (expression_statement "iVar2 = 3;" (assignment_expression "iVar2 = 3" identifier = number_literal) ;) (expression_statement "iVar3 = unaff_EDI + 0x5815e;" (assignment_expression "iVar3 = unaff_EDI + 0x5815e" identifier = (binary_expression "unaff_EDI + 0x5815e" identifier + number_literal)) ;) }) (else_clause "else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" else (compound_statement "{\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" { (expression_statement "iVar2 = 4;" (assignment_expression "iVar2 = 4" identifier = number_literal) ;) (expression_statement "iVar3 = unaff_EDI + 0x58142;" (assignment_expression "iVar3 = unaff_EDI + 0x58142" identifier = (binary_expression "unaff_EDI + 0x58142" identifier + number_literal)) ;) }))) (expression_statement "iVar2 = iVar2 + 4;" (assignment_expression "iVar2 = iVar2 + 4" identifier = (binary_expression "iVar2 + 4" identifier + number_literal)) ;) (if_statement "if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }" if (parenthesized_expression "(*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2)" ( (binary_expression "*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2" (pointer_expression "*(uint *)(iVar1 + 0xc + iVar2 * 4)" * (cast_expression "(uint *)(iVar1 + 0xc + iVar2 * 4)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0xc + iVar2 * 4)" ( (binary_expression "iVar1 + 0xc + iVar2 * 4" (binary_expression "iVar1 + 0xc" identifier + number_literal) + (binary_expression "iVar2 * 4" identifier * number_literal)) )))) < number_literal) )) (compound_statement "{\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }" { (expression_statement "FUN_00071060();" (call_expression "FUN_00071060()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = *(int *)(iVar3 + 0x14) + 4;" (assignment_expression "iVar2 = *(int *)(iVar3 + 0x14) + 4" identifier = (binary_expression "*(int *)(iVar3 + 0x14) + 4" (pointer_expression "*(int *)(iVar3 + 0x14)" * (cast_expression "(int *)(iVar3 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + 0x14)" ( (binary_expression "iVar3 + 0x14" identifier + number_literal) )))) + number_literal)) ;) })) (expression_statement "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;" (assignment_expression "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3" (pointer_expression "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4)" * (cast_expression "(undefined4 *)(iVar1 + 0xc + iVar2 * 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0xc + iVar2 * 4)" ( (binary_expression "iVar1 + 0xc + iVar2 * 4" (binary_expression "iVar1 + 0xc" identifier + number_literal) + (binary_expression "iVar2 * 4" identifier * number_literal)) )))) = number_literal) ;) })) })) (labeled_statement "LAB_0007167f:\n  FUN_00071570(1);" statement_identifier : (expression_statement "FUN_00071570(1);" (call_expression "FUN_00071570(1)" identifier (argument_list "(1)" ( number_literal ))) ;)) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) >> LIT) )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != LIT) )) (goto_statement goto statement_identifier ;)) })) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT == LIT) )) || (parenthesized_expression ( (binary_expression IDENT == LIT) ))) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }))) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression IDENT + LIT) + (binary_expression IDENT * LIT)) )))) < LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT)) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression IDENT + LIT) + (binary_expression IDENT * LIT)) )))) = LIT) ;) })) })) (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( LIT ))) ;)) (return_statement return ;) })))
(function_definition "void FUN_00071660(void)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}" (primitive_type "void") (function_declarator "FUN_00071660(void)" (identifier "FUN_00071660") (parameter_list "(void)" (( "(") (parameter_declaration "void" (primitive_type "void")) () ")"))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int *piVar4;\n  int unaff_EDI;\n  undefined8 uVar5;\n  \n  uVar5 = FUN_0004e9eb();\n  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);\n  iVar1 = (int)uVar5;\n  iVar3 = piVar4[4];\n  if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }\nLAB_0007167f:\n  FUN_00071570(1);\n  return;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "int *piVar4;" (primitive_type "int") (pointer_declarator "*piVar4" (* "*") (identifier "piVar4")) (; ";")) (declaration "int unaff_EDI;" (primitive_type "int") (identifier "unaff_EDI") (; ";")) (declaration "undefined8 uVar5;" (type_identifier "undefined8") (identifier "uVar5") (; ";")) (expression_statement "uVar5 = FUN_0004e9eb();" (assignment_expression "uVar5 = FUN_0004e9eb()" (identifier "uVar5") (= "=") (call_expression "FUN_0004e9eb()" (identifier "FUN_0004e9eb") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "piVar4 = (int *)((ulonglong)uVar5 >> 0x20);" (assignment_expression "piVar4 = (int *)((ulonglong)uVar5 >> 0x20)" (identifier "piVar4") (= "=") (cast_expression "(int *)((ulonglong)uVar5 >> 0x20)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((ulonglong)uVar5 >> 0x20)" (( "(") (binary_expression "(ulonglong)uVar5 >> 0x20" (cast_expression "(ulonglong)uVar5" (( "(") (type_descriptor "ulonglong" (type_identifier "ulonglong")) () ")") (identifier "uVar5")) (>> ">>") (number_literal "0x20")) () ")")))) (; ";")) (expression_statement "iVar1 = (int)uVar5;" (assignment_expression "iVar1 = (int)uVar5" (identifier "iVar1") (= "=") (cast_expression "(int)uVar5" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar5"))) (; ";")) (expression_statement "iVar3 = piVar4[4];" (assignment_expression "iVar3 = piVar4[4]" (identifier "iVar3") (= "=") (subscript_expression "piVar4[4]" (identifier "piVar4") ([ "[") (number_literal "4") (] "]"))) (; ";")) (if_statement "if (*piVar4 == 0xfb) {\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }" (if "if") (parenthesized_expression "(*piVar4 == 0xfb)" (( "(") (binary_expression "*piVar4 == 0xfb" (pointer_expression "*piVar4" (* "*") (identifier "piVar4")) (== "==") (number_literal "0xfb")) () ")")) (compound_statement "{\n    if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }\n    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }\n  }" ({ "{") (if_statement "if (iVar3 == 0x1f) {\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }" (if "if") (parenthesized_expression "(iVar3 == 0x1f)" (( "(") (binary_expression "iVar3 == 0x1f" (identifier "iVar3") (== "==") (number_literal "0x1f")) () ")")) (compound_statement "{\n      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));\n      iVar3 = piVar4[4];\n      if (*piVar4 != 0xfb) goto LAB_0007167f;\n    }" ({ "{") (expression_statement "FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));" (call_expression "FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18))" (identifier "FUN_00070d90") (argument_list "(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18))" (( "(") (identifier "iVar1") (, ",") (pointer_expression "*(undefined4 *)(iVar1 + 0x14)" (* "*") (cast_expression "(undefined4 *)(iVar1 + 0x14)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0x14)" (( "(") (binary_expression "iVar1 + 0x14" (identifier "iVar1") (+ "+") (number_literal "0x14")) () ")")))) (, ",") (pointer_expression "*(undefined4 *)(iVar1 + 0x18)" (* "*") (cast_expression "(undefined4 *)(iVar1 + 0x18)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0x18)" (( "(") (binary_expression "iVar1 + 0x18" (identifier "iVar1") (+ "+") (number_literal "0x18")) () ")")))) () ")"))) (; ";")) (expression_statement "iVar3 = piVar4[4];" (assignment_expression "iVar3 = piVar4[4]" (identifier "iVar3") (= "=") (subscript_expression "piVar4[4]" (identifier "piVar4") ([ "[") (number_literal "4") (] "]"))) (; ";")) (if_statement "if (*piVar4 != 0xfb) goto LAB_0007167f;" (if "if") (parenthesized_expression "(*piVar4 != 0xfb)" (( "(") (binary_expression "*piVar4 != 0xfb" (pointer_expression "*piVar4" (* "*") (identifier "piVar4")) (!= "!=") (number_literal "0xfb")) () ")")) (goto_statement "goto LAB_0007167f;" (goto "goto") (statement_identifier "LAB_0007167f") (; ";"))) (} "}"))) (if_statement "if ((iVar3 == 0x27) || (iVar3 == 0x24)) {\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }" (if "if") (parenthesized_expression "((iVar3 == 0x27) || (iVar3 == 0x24))" (( "(") (binary_expression "(iVar3 == 0x27) || (iVar3 == 0x24)" (parenthesized_expression "(iVar3 == 0x27)" (( "(") (binary_expression "iVar3 == 0x27" (identifier "iVar3") (== "==") (number_literal "0x27")) () ")")) (|| "||") (parenthesized_expression "(iVar3 == 0x24)" (( "(") (binary_expression "iVar3 == 0x24" (identifier "iVar3") (== "==") (number_literal "0x24")) () ")"))) () ")")) (compound_statement "{\n      if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }\n      iVar2 = iVar2 + 4;\n      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }\n      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;\n    }" ({ "{") (if_statement "if (iVar3 == 0x27) {\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }\n      else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" (if "if") (parenthesized_expression "(iVar3 == 0x27)" (( "(") (binary_expression "iVar3 == 0x27" (identifier "iVar3") (== "==") (number_literal "0x27")) () ")")) (compound_statement "{\n        iVar2 = 3;\n        iVar3 = unaff_EDI + 0x5815e;\n      }" ({ "{") (expression_statement "iVar2 = 3;" (assignment_expression "iVar2 = 3" (identifier "iVar2") (= "=") (number_literal "3")) (; ";")) (expression_statement "iVar3 = unaff_EDI + 0x5815e;" (assignment_expression "iVar3 = unaff_EDI + 0x5815e" (identifier "iVar3") (= "=") (binary_expression "unaff_EDI + 0x5815e" (identifier "unaff_EDI") (+ "+") (number_literal "0x5815e"))) (; ";")) (} "}")) (else_clause "else {\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" (else "else") (compound_statement "{\n        iVar2 = 4;\n        iVar3 = unaff_EDI + 0x58142;\n      }" ({ "{") (expression_statement "iVar2 = 4;" (assignment_expression "iVar2 = 4" (identifier "iVar2") (= "=") (number_literal "4")) (; ";")) (expression_statement "iVar3 = unaff_EDI + 0x58142;" (assignment_expression "iVar3 = unaff_EDI + 0x58142" (identifier "iVar3") (= "=") (binary_expression "unaff_EDI + 0x58142" (identifier "unaff_EDI") (+ "+") (number_literal "0x58142"))) (; ";")) (} "}")))) (expression_statement "iVar2 = iVar2 + 4;" (assignment_expression "iVar2 = iVar2 + 4" (identifier "iVar2") (= "=") (binary_expression "iVar2 + 4" (identifier "iVar2") (+ "+") (number_literal "4"))) (; ";")) (if_statement "if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }" (if "if") (parenthesized_expression "(*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2)" (( "(") (binary_expression "*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2" (pointer_expression "*(uint *)(iVar1 + 0xc + iVar2 * 4)" (* "*") (cast_expression "(uint *)(iVar1 + 0xc + iVar2 * 4)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0xc + iVar2 * 4)" (( "(") (binary_expression "iVar1 + 0xc + iVar2 * 4" (binary_expression "iVar1 + 0xc" (identifier "iVar1") (+ "+") (number_literal "0xc")) (+ "+") (binary_expression "iVar2 * 4" (identifier "iVar2") (* "*") (number_literal "4"))) () ")")))) (< "<") (number_literal "2")) () ")")) (compound_statement "{\n        FUN_00071060();\n        iVar2 = *(int *)(iVar3 + 0x14) + 4;\n      }" ({ "{") (expression_statement "FUN_00071060();" (call_expression "FUN_00071060()" (identifier "FUN_00071060") (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "iVar2 = *(int *)(iVar3 + 0x14) + 4;" (assignment_expression "iVar2 = *(int *)(iVar3 + 0x14) + 4" (identifier "iVar2") (= "=") (binary_expression "*(int *)(iVar3 + 0x14) + 4" (pointer_expression "*(int *)(iVar3 + 0x14)" (* "*") (cast_expression "(int *)(iVar3 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar3 + 0x14)" (( "(") (binary_expression "iVar3 + 0x14" (identifier "iVar3") (+ "+") (number_literal "0x14")) () ")")))) (+ "+") (number_literal "4"))) (; ";")) (} "}"))) (expression_statement "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;" (assignment_expression "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3" (pointer_expression "*(undefined4 *)(iVar1 + 0xc + iVar2 * 4)" (* "*") (cast_expression "(undefined4 *)(iVar1 + 0xc + iVar2 * 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0xc + iVar2 * 4)" (( "(") (binary_expression "iVar1 + 0xc + iVar2 * 4" (binary_expression "iVar1 + 0xc" (identifier "iVar1") (+ "+") (number_literal "0xc")) (+ "+") (binary_expression "iVar2 * 4" (identifier "iVar2") (* "*") (number_literal "4"))) () ")")))) (= "=") (number_literal "3")) (; ";")) (} "}"))) (} "}"))) (labeled_statement "LAB_0007167f:\n  FUN_00071570(1);" (statement_identifier "LAB_0007167f") (: ":") (expression_statement "FUN_00071570(1);" (call_expression "FUN_00071570(1)" (identifier "FUN_00071570") (argument_list "(1)" (( "(") (number_literal "1") () ")"))) (; ";"))) (return_statement "return;" (return "return") (; ";")) (} "}")))

/* WARNING: Enum "anon_enum_32": Some values do not have unique names */

void function_1(type_1 telnet,type_2 *o)

{
  type_1 telnet_00;
  int iVar1;
  int var_3;
  int *piVar3;
  type_2 *var_2;
  type_1 unaff_EBX;
  int unaff_ESI;
  int var_5;
  type_3 uVar4;
  int option;
  
  option = var_5;
  uVar4 = var_1();
  piVar3 = (int *)((type_4)uVar4 >> 0x20);
  telnet_00 = (type_1)uVar4;
  var_2 = (type_2 *)*piVar3;
  var_3 = piVar3[4];
  if (var_2 == (type_2 *)0xfb) {
    if (var_3 == 0x1f) {
      var_4(telnet_00,telnet_00->term_width,telnet_00->term_height);
      var_2 = (type_2 *)*piVar3;
      var_3 = piVar3[4];
      if (var_2 != (type_2 *)0xfb) goto LAB_0007167f;
    }
    if ((var_3 == 0x27) || (var_3 == 0x24)) {
      if (var_3 == 0x27) {
        iVar1 = 3;
        var_3 = var_5 + 0x5815e;
      }
      else {
        iVar1 = 4;
        var_3 = var_5 + 0x58142;
      }
      if ((type_5)telnet_00->opt_states[iVar1] < 2) {
        var_6(unaff_EBX,unaff_ESI,option);
        iVar1 = *(int *)(var_3 + 0x14);
      }
      telnet_00->opt_states[iVar1] = 3;
      var_2 = (type_2 *)*piVar3;
      var_3 = piVar3[4];
    }
    else {
      var_2 = (type_2 *)*piVar3;
    }
  }
LAB_0007167f:
  var_7(telnet_00,var_2,var_3,(type_2 *)0x1);
  return;
}


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

void MASKED(void)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int *piVar4;
  int unaff_EDI;
  undefined8 uVar5;
  
  uVar5 = FUN_0004e9eb();
  piVar4 = (int *)((ulonglong)uVar5 >> 0x20);
  iVar1 = (int)uVar5;
  iVar3 = piVar4[4];
  if (*piVar4 == 0xfb) {
    if (iVar3 == 0x1f) {
      FUN_00070d90(iVar1,*(undefined4 *)(iVar1 + 0x14),*(undefined4 *)(iVar1 + 0x18));
      iVar3 = piVar4[4];
      if (*piVar4 != 0xfb) goto LAB_0007167f;
    }
    if ((iVar3 == 0x27) || (iVar3 == 0x24)) {
      if (iVar3 == 0x27) {
        iVar2 = 3;
        iVar3 = unaff_EDI + 0x5815e;
      }
      else {
        iVar2 = 4;
        iVar3 = unaff_EDI + 0x58142;
      }
      iVar2 = iVar2 + 4;
      if (*(uint *)(iVar1 + 0xc + iVar2 * 4) < 2) {
        FUN_00071060();
        iVar2 = *(int *)(iVar3 + 0x14) + 4;
      }
      *(undefined4 *)(iVar1 + 0xc + iVar2 * 4) = 3;
    }
  }
LAB_0007167f:
  FUN_00071570(1);
  return;
}

