
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Enum "anon_enum_32": Some values do not have unique names */

void __regparm3 s_wrpkt(Ssh_conflict ssh,Packet *pkt)

{
  uchar *puVar1;
  Socket ppsVar2;
  int iVar3;
  tree234 *t;
  void *pvVar4;
  int in_GS_OFFSET;
  int offset;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x3a54d;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  iVar3 = s_wrpkt_prepare(ssh,pkt,&offset);
  puVar1 = pkt->data;
  if (ssh->logctx != (void *)0x0) {
    log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0
               ,(char *)0x0);
  }
  ppsVar2 = ssh->s;
  if (ppsVar2 != (Socket)0x0) {
    iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);
    if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {
      ssh->overall_bufsize = iVar3;
      t = ssh->channels;
      ssh->throttled_all = 1;
      if (t != (tree234 *)0x0) {
        iVar3 = 0;
        while( true ) {
          pvVar4 = index234(t,iVar3);
          if (pvVar4 == (void *)0x0) break;
          if (*(int *)((int)pvVar4 + 0xc) == 1) {
            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);
          }
          else if (*(int *)((int)pvVar4 + 0xc) == 3) {
            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);
          }
          t = ssh->channels;
          iVar3 = iVar3 + 1;
        }
      }
    }
  }
  safefree(pkt->data);
  safefree(pkt);
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail_local();
}



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

void __regparm3 FUN_0003a540(int param_1,int param_2)

{
  int iVar1;
  int *piVar2;
  undefined4 uVar3;
  int iVar4;
  int iVar5;
  int in_GS_OFFSET;
  undefined4 local_24;
  
  iVar1 = *(int *)(in_GS_OFFSET + 0x14);
  uVar3 = FUN_00038cb0();
  iVar4 = local_24 + *(int *)(param_2 + 0x10);
  if (*(int *)(param_1 + 0x18) != 0) {
    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);
  }
  piVar2 = *(int **)(param_1 + 0x10);
  if (piVar2 != (int *)0x0) {
    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);
    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {
      *(int *)(param_1 + 0x1a0) = iVar4;
      iVar4 = *(int *)(param_1 + 0x124);
      *(undefined4 *)(param_1 + 0x1a4) = 1;
      if (iVar4 != 0) {
        iVar5 = 0;
        while( true ) {
          iVar4 = FUN_00081c90(iVar4,iVar5);
          if (iVar4 == 0) break;
          if (*(int *)(iVar4 + 0xc) == 1) {
            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);
          }
          else if (*(int *)(iVar4 + 0xc) == 3) {
            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);
          }
          iVar4 = *(int *)(param_1 + 0x124);
          iVar5 = iVar5 + 1;
        }
      }
    }
  }
  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));
  FUN_0001dd30(param_2);
  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  FUN_0008eb20();
}


PUSH EBP
PUSH EDI
MOV EDI,EDX
PUSH ESI
MOV ESI,EAX
PUSH EBX
CALL 0x000149a0
ADD EBX,0x95843
SUB ESP,0x2c
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0x1c],EAX
XOR EAX,EAX
LEA ECX,[ESP + 0x18]
MOV EAX,ESI
CALL 0x00038cb0
MOV EDX,dword ptr [ESI + 0x18]
MOV EBP,dword ptr [ESP + 0x18]
ADD EBP,dword ptr [EDI + 0x10]
TEST EDX,EDX
JZ 0x0003a5a1
SUB ESP,0x4
PUSH 0x0
PUSH 0x0
PUSH 0x0
PUSH 0x0
PUSH 0x0
PUSH EAX
MOV dword ptr [ESP + 0x28],EAX
PUSH EBP
PUSH 0x0
PUSH -0x1
PUSH 0x1
PUSH EDX
CALL 0x0001b790
ADD ESP,0x30
MOV EAX,dword ptr [ESP + 0xc]
MOV EDX,dword ptr [ESI + 0x10]
TEST EDX,EDX
JZ 0x0003a630
SUB ESP,0x4
MOV ECX,dword ptr [EDX]
PUSH EAX
PUSH EBP
PUSH EDX
CALL dword ptr [ECX + 0x8]
ADD ESP,0x10
CMP EAX,0x8000
JLE 0x0003a630
CMP dword ptr [ESI + 0x1a4],0x1
JZ 0x0003a630
MOV dword ptr [ESI + 0x1a0],EAX
MOV EAX,dword ptr [ESI + 0x124]
MOV dword ptr [ESI + 0x1a4],0x1
TEST EAX,EAX
JZ 0x0003a630
XOR EBP,EBP
JMP 0x0003a5f9
MOV EAX,dword ptr [ESI + 0x124]
ADD EBP,0x1
SUB ESP,0x8
PUSH EBP
PUSH EAX
CALL 0x00081c90
ADD ESP,0x10
TEST EAX,EAX
JZ 0x0003a630
MOV EDX,dword ptr [EAX + 0xc]
CMP EDX,0x1
JZ 0x0003a660
CMP EDX,0x3
JNZ 0x0003a5f0
SUB ESP,0x8
PUSH 0x1
PUSH dword ptr [EAX + 0x4c]
CALL 0x0001f630
ADD ESP,0x10
JMP 0x0003a5f0
SUB ESP,0xc
PUSH dword ptr [EDI + 0x10]
CALL 0x0001dd30
MOV dword ptr [ESP],EDI
CALL 0x0001dd30
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0x1c]
XOR EAX,dword ptr GS:[0x14]
JNZ 0x0003a675
ADD ESP,0x2c
POP EBX
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0x8
PUSH 0x1
PUSH dword ptr [EAX + 0x4c]
CALL 0x0008daf0
ADD ESP,0x10
JMP 0x0003a5f0
CALL 0x0008eb20
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid __regparm3 FUN_0003a540(int param_1,int param_2)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0008eb20();\n}\n\n" comment (function_definition "void __regparm3 FUN_0003a540(int param_1,int param_2)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0008eb20();\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "FUN_0003a540(int param_1,int param_2)" identifier (parameter_list "(int param_1,int param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0008eb20();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "undefined4 uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "undefined4 local_24;" type_identifier identifier ;) (expression_statement "iVar1 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "iVar1 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "uVar3 = FUN_00038cb0();" (assignment_expression "uVar3 = FUN_00038cb0()" identifier = (call_expression "FUN_00038cb0()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar4 = local_24 + *(int *)(param_2 + 0x10);" (assignment_expression "iVar4 = local_24 + *(int *)(param_2 + 0x10)" identifier = (binary_expression "local_24 + *(int *)(param_2 + 0x10)" identifier + (pointer_expression "*(int *)(param_2 + 0x10)" * (cast_expression "(int *)(param_2 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x10)" ( (binary_expression "param_2 + 0x10" identifier + number_literal) )))))) ;) (if_statement "if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" ( (binary_expression "*(int *)(param_1 + 0x18) != 0" (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }" { (expression_statement "FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);" (call_expression "FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0)" identifier (argument_list "(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0)" ( (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) , number_literal , number_literal , number_literal , identifier , identifier , number_literal , number_literal , number_literal , number_literal , number_literal ))) ;) })) (expression_statement "piVar2 = *(int **)(param_1 + 0x10);" (assignment_expression "piVar2 = *(int **)(param_1 + 0x10)" identifier = (pointer_expression "*(int **)(param_1 + 0x10)" * (cast_expression "(int **)(param_1 + 0x10)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) (if_statement "if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }" if (parenthesized_expression "(piVar2 != (int *)0x0)" ( (binary_expression "piVar2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }" { (expression_statement "iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);" (assignment_expression "iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3)" identifier = (call_expression "(**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3)" (parenthesized_expression "(**(code **)(*piVar2 + 8))" ( (pointer_expression "**(code **)(*piVar2 + 8)" * (pointer_expression "*(code **)(*piVar2 + 8)" * (cast_expression "(code **)(*piVar2 + 8)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(*piVar2 + 8)" ( (binary_expression "*piVar2 + 8" (pointer_expression "*piVar2" * identifier) + number_literal) ))))) )) (argument_list "(piVar2,iVar4,uVar3)" ( identifier , identifier , identifier )))) ;) (if_statement "if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }" if (parenthesized_expression "((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1))" ( (binary_expression "(0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)" (parenthesized_expression "(0x8000 < iVar4)" ( (binary_expression "0x8000 < iVar4" number_literal < identifier) )) && (parenthesized_expression "(*(int *)(param_1 + 0x1a4) != 1)" ( (binary_expression "*(int *)(param_1 + 0x1a4) != 1" (pointer_expression "*(int *)(param_1 + 0x1a4)" * (cast_expression "(int *)(param_1 + 0x1a4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x1a4)" ( (binary_expression "param_1 + 0x1a4" identifier + number_literal) )))) != number_literal) ))) )) (compound_statement "{\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }" { (expression_statement "*(int *)(param_1 + 0x1a0) = iVar4;" (assignment_expression "*(int *)(param_1 + 0x1a0) = iVar4" (pointer_expression "*(int *)(param_1 + 0x1a0)" * (cast_expression "(int *)(param_1 + 0x1a0)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x1a0)" ( (binary_expression "param_1 + 0x1a0" identifier + number_literal) )))) = identifier) ;) (expression_statement "iVar4 = *(int *)(param_1 + 0x124);" (assignment_expression "iVar4 = *(int *)(param_1 + 0x124)" identifier = (pointer_expression "*(int *)(param_1 + 0x124)" * (cast_expression "(int *)(param_1 + 0x124)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x124)" ( (binary_expression "param_1 + 0x124" identifier + number_literal) ))))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x1a4) = 1;" (assignment_expression "*(undefined4 *)(param_1 + 0x1a4) = 1" (pointer_expression "*(undefined4 *)(param_1 + 0x1a4)" * (cast_expression "(undefined4 *)(param_1 + 0x1a4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x1a4)" ( (binary_expression "param_1 + 0x1a4" identifier + number_literal) )))) = number_literal) ;) (if_statement "if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }" { (expression_statement "iVar5 = 0;" (assignment_expression "iVar5 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }" { (expression_statement "iVar4 = FUN_00081c90(iVar4,iVar5);" (assignment_expression "iVar4 = FUN_00081c90(iVar4,iVar5)" identifier = (call_expression "FUN_00081c90(iVar4,iVar5)" identifier (argument_list "(iVar4,iVar5)" ( identifier , identifier )))) ;) (if_statement "if (iVar4 == 0) break;" if (parenthesized_expression "(iVar4 == 0)" ( (binary_expression "iVar4 == 0" identifier == number_literal) )) (break_statement "break;" break ;)) (if_statement "if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" if (parenthesized_expression "(*(int *)(iVar4 + 0xc) == 1)" ( (binary_expression "*(int *)(iVar4 + 0xc) == 1" (pointer_expression "*(int *)(iVar4 + 0xc)" * (cast_expression "(int *)(iVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0xc)" ( (binary_expression "iVar4 + 0xc" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" { (expression_statement "FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);" (call_expression "FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1)" identifier (argument_list "(*(undefined4 *)(iVar4 + 0x4c),1)" ( (pointer_expression "*(undefined4 *)(iVar4 + 0x4c)" * (cast_expression "(undefined4 *)(iVar4 + 0x4c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x4c)" ( (binary_expression "iVar4 + 0x4c" identifier + number_literal) )))) , number_literal ))) ;) }) (else_clause "else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" else (if_statement "if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" if (parenthesized_expression "(*(int *)(iVar4 + 0xc) == 3)" ( (binary_expression "*(int *)(iVar4 + 0xc) == 3" (pointer_expression "*(int *)(iVar4 + 0xc)" * (cast_expression "(int *)(iVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0xc)" ( (binary_expression "iVar4 + 0xc" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" { (expression_statement "FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);" (call_expression "FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1)" identifier (argument_list "(*(undefined4 *)(iVar4 + 0x4c),1)" ( (pointer_expression "*(undefined4 *)(iVar4 + 0x4c)" * (cast_expression "(undefined4 *)(iVar4 + 0x4c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x4c)" ( (binary_expression "iVar4 + 0x4c" identifier + number_literal) )))) , number_literal ))) ;) })))) (expression_statement "iVar4 = *(int *)(param_1 + 0x124);" (assignment_expression "iVar4 = *(int *)(param_1 + 0x124)" identifier = (pointer_expression "*(int *)(param_1 + 0x124)" * (cast_expression "(int *)(param_1 + 0x124)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x124)" ( (binary_expression "param_1 + 0x124" identifier + number_literal) ))))) ;) (expression_statement "iVar5 = iVar5 + 1;" (assignment_expression "iVar5 = iVar5 + 1" identifier = (binary_expression "iVar5 + 1" identifier + number_literal)) ;) })) })) })) })) (expression_statement "FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));" (call_expression "FUN_0001dd30(*(undefined4 *)(param_2 + 0x10))" identifier (argument_list "(*(undefined4 *)(param_2 + 0x10))" ( (pointer_expression "*(undefined4 *)(param_2 + 0x10)" * (cast_expression "(undefined4 *)(param_2 + 0x10)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x10)" ( (binary_expression "param_2 + 0x10" identifier + number_literal) )))) ))) ;) (expression_statement "FUN_0001dd30(param_2);" (call_expression "FUN_0001dd30(param_2)" identifier (argument_list "(param_2)" ( identifier ))) ;) (if_statement "if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" if (parenthesized_expression "(iVar1 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "iVar1 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) comment (expression_statement "FUN_0008eb20();" (call_expression "FUN_0008eb20()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Enum "anon_enum_32": Some values do not have unique names */\n\nvoid __regparm3 s_wrpkt(Ssh_conflict ssh,Packet *pkt)\n\n{\n  uchar *puVar1;\n  Socket ppsVar2;\n  int iVar3;\n  tree234 *t;\n  void *pvVar4;\n  int in_GS_OFFSET;\n  int offset;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3a54d;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar3 = s_wrpkt_prepare(ssh,pkt,&offset);\n  puVar1 = pkt->data;\n  if (ssh->logctx != (void *)0x0) {\n    log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0);\n  }\n  ppsVar2 = ssh->s;\n  if (ppsVar2 != (Socket)0x0) {\n    iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);\n    if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }\n  }\n  safefree(pkt->data);\n  safefree(pkt);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}\n\n" comment comment (function_definition "void __regparm3 s_wrpkt(Ssh_conflict ssh,Packet *pkt)\n\n{\n  uchar *puVar1;\n  Socket ppsVar2;\n  int iVar3;\n  tree234 *t;\n  void *pvVar4;\n  int in_GS_OFFSET;\n  int offset;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3a54d;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar3 = s_wrpkt_prepare(ssh,pkt,&offset);\n  puVar1 = pkt->data;\n  if (ssh->logctx != (void *)0x0) {\n    log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0);\n  }\n  ppsVar2 = ssh->s;\n  if (ppsVar2 != (Socket)0x0) {\n    iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);\n    if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }\n  }\n  safefree(pkt->data);\n  safefree(pkt);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "s_wrpkt(Ssh_conflict ssh,Packet *pkt)" identifier (parameter_list "(Ssh_conflict ssh,Packet *pkt)" ( (parameter_declaration "Ssh_conflict ssh" type_identifier identifier) , (parameter_declaration "Packet *pkt" type_identifier (pointer_declarator "*pkt" * identifier)) ))) (compound_statement "{\n  uchar *puVar1;\n  Socket ppsVar2;\n  int iVar3;\n  tree234 *t;\n  void *pvVar4;\n  int in_GS_OFFSET;\n  int offset;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3a54d;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar3 = s_wrpkt_prepare(ssh,pkt,&offset);\n  puVar1 = pkt->data;\n  if (ssh->logctx != (void *)0x0) {\n    log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0);\n  }\n  ppsVar2 = ssh->s;\n  if (ppsVar2 != (Socket)0x0) {\n    iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);\n    if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }\n  }\n  safefree(pkt->data);\n  safefree(pkt);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" { (declaration "uchar *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "Socket ppsVar2;" type_identifier identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "tree234 *t;" type_identifier (pointer_declarator "*t" * identifier) ;) (declaration "void *pvVar4;" primitive_type (pointer_declarator "*pvVar4" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "int offset;" primitive_type identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x3a54d;" (assignment_expression "uStack_14 = 0x3a54d" identifier = number_literal) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = s_wrpkt_prepare(ssh,pkt,&offset);" (assignment_expression "iVar3 = s_wrpkt_prepare(ssh,pkt,&offset)" identifier = (call_expression "s_wrpkt_prepare(ssh,pkt,&offset)" identifier (argument_list "(ssh,pkt,&offset)" ( identifier , identifier , (pointer_expression "&offset" & identifier) )))) ;) (expression_statement "puVar1 = pkt->data;" (assignment_expression "puVar1 = pkt->data" identifier = (field_expression "pkt->data" identifier -> field_identifier)) ;) (if_statement "if (ssh->logctx != (void *)0x0) {\n    log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0);\n  }" if (parenthesized_expression "(ssh->logctx != (void *)0x0)" ( (binary_expression "ssh->logctx != (void *)0x0" (field_expression "ssh->logctx" identifier -> field_identifier) != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0);\n  }" { (expression_statement "log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0);" (call_expression "log_packet(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0)" identifier (argument_list "(ssh->logctx,1,-1,(char *)0x0,puVar1 + offset,iVar3,0,(logblank_t *)0x0,(ulong *)0x0,0\n               ,(char *)0x0)" ( (field_expression "ssh->logctx" identifier -> field_identifier) , number_literal , number_literal , (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) , (binary_expression "puVar1 + offset" identifier + identifier) , identifier , number_literal , (cast_expression "(logblank_t *)0x0" ( (type_descriptor "logblank_t *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) , (cast_expression "(ulong *)0x0" ( (type_descriptor "ulong *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) , number_literal , (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) ))) ;) })) (expression_statement "ppsVar2 = ssh->s;" (assignment_expression "ppsVar2 = ssh->s" identifier = (field_expression "ssh->s" identifier -> field_identifier)) ;) (if_statement "if (ppsVar2 != (Socket)0x0) {\n    iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);\n    if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }\n  }" if (parenthesized_expression "(ppsVar2 != (Socket)0x0)" ( (binary_expression "ppsVar2 != (Socket)0x0" identifier != (cast_expression "(Socket)0x0" ( (type_descriptor "Socket" type_identifier) ) number_literal)) )) (compound_statement "{\n    iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);\n    if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }\n  }" { (expression_statement "iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3);" (assignment_expression "iVar3 = (*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3)" identifier = (call_expression "(*(*ppsVar2)->write)(ppsVar2,(char *)(puVar1 + offset),iVar3)" (parenthesized_expression "(*(*ppsVar2)->write)" ( (pointer_expression "*(*ppsVar2)->write" * (field_expression "(*ppsVar2)->write" (parenthesized_expression "(*ppsVar2)" ( (pointer_expression "*ppsVar2" * identifier) )) -> field_identifier)) )) (argument_list "(ppsVar2,(char *)(puVar1 + offset),iVar3)" ( identifier , (cast_expression "(char *)(puVar1 + offset)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar1 + offset)" ( (binary_expression "puVar1 + offset" identifier + identifier) ))) , identifier )))) ;) (if_statement "if ((0x8000 < iVar3) && (ssh->throttled_all != 1)) {\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }" if (parenthesized_expression "((0x8000 < iVar3) && (ssh->throttled_all != 1))" ( (binary_expression "(0x8000 < iVar3) && (ssh->throttled_all != 1)" (parenthesized_expression "(0x8000 < iVar3)" ( (binary_expression "0x8000 < iVar3" number_literal < identifier) )) && (parenthesized_expression "(ssh->throttled_all != 1)" ( (binary_expression "ssh->throttled_all != 1" (field_expression "ssh->throttled_all" identifier -> field_identifier) != number_literal) ))) )) (compound_statement "{\n      ssh->overall_bufsize = iVar3;\n      t = ssh->channels;\n      ssh->throttled_all = 1;\n      if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }\n    }" { (expression_statement "ssh->overall_bufsize = iVar3;" (assignment_expression "ssh->overall_bufsize = iVar3" (field_expression "ssh->overall_bufsize" identifier -> field_identifier) = identifier) ;) (expression_statement "t = ssh->channels;" (assignment_expression "t = ssh->channels" identifier = (field_expression "ssh->channels" identifier -> field_identifier)) ;) (expression_statement "ssh->throttled_all = 1;" (assignment_expression "ssh->throttled_all = 1" (field_expression "ssh->throttled_all" identifier -> field_identifier) = number_literal) ;) (if_statement "if (t != (tree234 *)0x0) {\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }" if (parenthesized_expression "(t != (tree234 *)0x0)" ( (binary_expression "t != (tree234 *)0x0" identifier != (cast_expression "(tree234 *)0x0" ( (type_descriptor "tree234 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        iVar3 = 0;\n        while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }\n      }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n          pvVar4 = index234(t,iVar3);\n          if (pvVar4 == (void *)0x0) break;\n          if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }\n          t = ssh->channels;\n          iVar3 = iVar3 + 1;\n        }" { (expression_statement "pvVar4 = index234(t,iVar3);" (assignment_expression "pvVar4 = index234(t,iVar3)" identifier = (call_expression "index234(t,iVar3)" identifier (argument_list "(t,iVar3)" ( identifier , identifier )))) ;) (if_statement "if (pvVar4 == (void *)0x0) break;" if (parenthesized_expression "(pvVar4 == (void *)0x0)" ( (binary_expression "pvVar4 == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (break_statement "break;" break ;)) (if_statement "if (*(int *)((int)pvVar4 + 0xc) == 1) {\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }\n          else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }" if (parenthesized_expression "(*(int *)((int)pvVar4 + 0xc) == 1)" ( (binary_expression "*(int *)((int)pvVar4 + 0xc) == 1" (pointer_expression "*(int *)((int)pvVar4 + 0xc)" * (cast_expression "(int *)((int)pvVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)pvVar4 + 0xc)" ( (binary_expression "(int)pvVar4 + 0xc" (cast_expression "(int)pvVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) == number_literal) )) (compound_statement "{\n            x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);\n          }" { (expression_statement "x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1);" (call_expression "x11_override_throttle(*(X11Connection **)((int)pvVar4 + 0x4c),1)" identifier (argument_list "(*(X11Connection **)((int)pvVar4 + 0x4c),1)" ( (pointer_expression "*(X11Connection **)((int)pvVar4 + 0x4c)" * (cast_expression "(X11Connection **)((int)pvVar4 + 0x4c)" ( (type_descriptor "X11Connection **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "((int)pvVar4 + 0x4c)" ( (binary_expression "(int)pvVar4 + 0x4c" (cast_expression "(int)pvVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) , number_literal ))) ;) }) (else_clause "else if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }" else (if_statement "if (*(int *)((int)pvVar4 + 0xc) == 3) {\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }" if (parenthesized_expression "(*(int *)((int)pvVar4 + 0xc) == 3)" ( (binary_expression "*(int *)((int)pvVar4 + 0xc) == 3" (pointer_expression "*(int *)((int)pvVar4 + 0xc)" * (cast_expression "(int *)((int)pvVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)pvVar4 + 0xc)" ( (binary_expression "(int)pvVar4 + 0xc" (cast_expression "(int)pvVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) == number_literal) )) (compound_statement "{\n            pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);\n          }" { (expression_statement "pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1);" (call_expression "pfd_override_throttle(*(PortForwarding **)((int)pvVar4 + 0x4c),1)" identifier (argument_list "(*(PortForwarding **)((int)pvVar4 + 0x4c),1)" ( (pointer_expression "*(PortForwarding **)((int)pvVar4 + 0x4c)" * (cast_expression "(PortForwarding **)((int)pvVar4 + 0x4c)" ( (type_descriptor "PortForwarding **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "((int)pvVar4 + 0x4c)" ( (binary_expression "(int)pvVar4 + 0x4c" (cast_expression "(int)pvVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) , number_literal ))) ;) })))) (expression_statement "t = ssh->channels;" (assignment_expression "t = ssh->channels" identifier = (field_expression "ssh->channels" identifier -> field_identifier)) ;) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) })) })) })) })) (expression_statement "safefree(pkt->data);" (call_expression "safefree(pkt->data)" identifier (argument_list "(pkt->data)" ( (field_expression "pkt->data" identifier -> field_identifier) ))) ;) (expression_statement "safefree(pkt);" (call_expression "safefree(pkt)" identifier (argument_list "(pkt)" ( identifier ))) ;) (if_statement "if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" if (parenthesized_expression "(local_20 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "void __regparm3 FUN_0003a540(int param_1,int param_2)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_0008eb20();\n}\n\n" (function_definition "void __regparm3 FUN_0003a540(int param_1,int param_2)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_0008eb20();\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "FUN_0003a540(int param_1,int param_2)" identifier (parameter_list "(int param_1,int param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_0008eb20();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "undefined4 uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "undefined4 local_24;" type_identifier identifier ;) (expression_statement "iVar1 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "iVar1 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "uVar3 = FUN_00038cb0();" (assignment_expression "uVar3 = FUN_00038cb0()" identifier = (call_expression "FUN_00038cb0()" identifier (argument_list "()" ( )))) ;) (expression_statement "iVar4 = local_24 + *(int *)(param_2 + 0x10);" (assignment_expression "iVar4 = local_24 + *(int *)(param_2 + 0x10)" identifier = (binary_expression "local_24 + *(int *)(param_2 + 0x10)" identifier + (pointer_expression "*(int *)(param_2 + 0x10)" * (cast_expression "(int *)(param_2 + 0x10)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x10)" ( (binary_expression "param_2 + 0x10" identifier + number_literal) )))))) ;) (if_statement "if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" ( (binary_expression "*(int *)(param_1 + 0x18) != 0" (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }" { (expression_statement "FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);" (call_expression "FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0)" identifier (argument_list "(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0)" ( (pointer_expression "*(int *)(param_1 + 0x18)" * (cast_expression "(int *)(param_1 + 0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) )))) , number_literal , number_literal , number_literal , identifier , identifier , number_literal , number_literal , number_literal , number_literal , number_literal ))) ;) })) (expression_statement "piVar2 = *(int **)(param_1 + 0x10);" (assignment_expression "piVar2 = *(int **)(param_1 + 0x10)" identifier = (pointer_expression "*(int **)(param_1 + 0x10)" * (cast_expression "(int **)(param_1 + 0x10)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))))) ;) (if_statement "if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }" if (parenthesized_expression "(piVar2 != (int *)0x0)" ( (binary_expression "piVar2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }" { (expression_statement "iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);" (assignment_expression "iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3)" identifier = (call_expression "(**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3)" (parenthesized_expression "(**(code **)(*piVar2 + 8))" ( (pointer_expression "**(code **)(*piVar2 + 8)" * (pointer_expression "*(code **)(*piVar2 + 8)" * (cast_expression "(code **)(*piVar2 + 8)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(*piVar2 + 8)" ( (binary_expression "*piVar2 + 8" (pointer_expression "*piVar2" * identifier) + number_literal) ))))) )) (argument_list "(piVar2,iVar4,uVar3)" ( identifier , identifier , identifier )))) ;) (if_statement "if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }" if (parenthesized_expression "((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1))" ( (binary_expression "(0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)" (parenthesized_expression "(0x8000 < iVar4)" ( (binary_expression "0x8000 < iVar4" number_literal < identifier) )) && (parenthesized_expression "(*(int *)(param_1 + 0x1a4) != 1)" ( (binary_expression "*(int *)(param_1 + 0x1a4) != 1" (pointer_expression "*(int *)(param_1 + 0x1a4)" * (cast_expression "(int *)(param_1 + 0x1a4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x1a4)" ( (binary_expression "param_1 + 0x1a4" identifier + number_literal) )))) != number_literal) ))) )) (compound_statement "{\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }" { (expression_statement "*(int *)(param_1 + 0x1a0) = iVar4;" (assignment_expression "*(int *)(param_1 + 0x1a0) = iVar4" (pointer_expression "*(int *)(param_1 + 0x1a0)" * (cast_expression "(int *)(param_1 + 0x1a0)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x1a0)" ( (binary_expression "param_1 + 0x1a0" identifier + number_literal) )))) = identifier) ;) (expression_statement "iVar4 = *(int *)(param_1 + 0x124);" (assignment_expression "iVar4 = *(int *)(param_1 + 0x124)" identifier = (pointer_expression "*(int *)(param_1 + 0x124)" * (cast_expression "(int *)(param_1 + 0x124)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x124)" ( (binary_expression "param_1 + 0x124" identifier + number_literal) ))))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x1a4) = 1;" (assignment_expression "*(undefined4 *)(param_1 + 0x1a4) = 1" (pointer_expression "*(undefined4 *)(param_1 + 0x1a4)" * (cast_expression "(undefined4 *)(param_1 + 0x1a4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x1a4)" ( (binary_expression "param_1 + 0x1a4" identifier + number_literal) )))) = number_literal) ;) (if_statement "if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }" if (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) (compound_statement "{\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }" { (expression_statement "iVar5 = 0;" (assignment_expression "iVar5 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }" { (expression_statement "iVar4 = FUN_00081c90(iVar4,iVar5);" (assignment_expression "iVar4 = FUN_00081c90(iVar4,iVar5)" identifier = (call_expression "FUN_00081c90(iVar4,iVar5)" identifier (argument_list "(iVar4,iVar5)" ( identifier , identifier )))) ;) (if_statement "if (iVar4 == 0) break;" if (parenthesized_expression "(iVar4 == 0)" ( (binary_expression "iVar4 == 0" identifier == number_literal) )) (break_statement "break;" break ;)) (if_statement "if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" if (parenthesized_expression "(*(int *)(iVar4 + 0xc) == 1)" ( (binary_expression "*(int *)(iVar4 + 0xc) == 1" (pointer_expression "*(int *)(iVar4 + 0xc)" * (cast_expression "(int *)(iVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0xc)" ( (binary_expression "iVar4 + 0xc" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" { (expression_statement "FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);" (call_expression "FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1)" identifier (argument_list "(*(undefined4 *)(iVar4 + 0x4c),1)" ( (pointer_expression "*(undefined4 *)(iVar4 + 0x4c)" * (cast_expression "(undefined4 *)(iVar4 + 0x4c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x4c)" ( (binary_expression "iVar4 + 0x4c" identifier + number_literal) )))) , number_literal ))) ;) }) (else_clause "else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" else (if_statement "if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" if (parenthesized_expression "(*(int *)(iVar4 + 0xc) == 3)" ( (binary_expression "*(int *)(iVar4 + 0xc) == 3" (pointer_expression "*(int *)(iVar4 + 0xc)" * (cast_expression "(int *)(iVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0xc)" ( (binary_expression "iVar4 + 0xc" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" { (expression_statement "FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);" (call_expression "FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1)" identifier (argument_list "(*(undefined4 *)(iVar4 + 0x4c),1)" ( (pointer_expression "*(undefined4 *)(iVar4 + 0x4c)" * (cast_expression "(undefined4 *)(iVar4 + 0x4c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x4c)" ( (binary_expression "iVar4 + 0x4c" identifier + number_literal) )))) , number_literal ))) ;) })))) (expression_statement "iVar4 = *(int *)(param_1 + 0x124);" (assignment_expression "iVar4 = *(int *)(param_1 + 0x124)" identifier = (pointer_expression "*(int *)(param_1 + 0x124)" * (cast_expression "(int *)(param_1 + 0x124)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x124)" ( (binary_expression "param_1 + 0x124" identifier + number_literal) ))))) ;) (expression_statement "iVar5 = iVar5 + 1;" (assignment_expression "iVar5 = iVar5 + 1" identifier = (binary_expression "iVar5 + 1" identifier + number_literal)) ;) })) })) })) })) (expression_statement "FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));" (call_expression "FUN_0001dd30(*(undefined4 *)(param_2 + 0x10))" identifier (argument_list "(*(undefined4 *)(param_2 + 0x10))" ( (pointer_expression "*(undefined4 *)(param_2 + 0x10)" * (cast_expression "(undefined4 *)(param_2 + 0x10)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x10)" ( (binary_expression "param_2 + 0x10" identifier + number_literal) )))) ))) ;) (expression_statement "FUN_0001dd30(param_2);" (call_expression "FUN_0001dd30(param_2)" identifier (argument_list "(param_2)" ( identifier ))) ;) (if_statement "if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" if (parenthesized_expression "(iVar1 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "iVar1 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "FUN_0008eb20();" (call_expression "FUN_0008eb20()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (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 IDENT + LIT) )))) != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT , LIT , LIT , IDENT , IDENT , LIT , LIT , LIT , LIT , LIT ))) ;) })) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) + LIT) ))))) )) (argument_list ( IDENT , IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression LIT < IDENT) )) && (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) ))) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (break_statement break ;)) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT ))) ;) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT ))) ;) })))) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) })) })) })) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (return_statement return ;) })) (expression_statement (call_expression IDENT (argument_list ( ))) ;) })))
(function_definition "void __regparm3 FUN_0003a540(int param_1,int param_2)\n\n{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_0008eb20();\n}" (primitive_type "void") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_0003a540(int param_1,int param_2)" (identifier "FUN_0003a540") (parameter_list "(int param_1,int param_2)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) () ")"))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  undefined4 uVar3;\n  int iVar4;\n  int iVar5;\n  int in_GS_OFFSET;\n  undefined4 local_24;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  uVar3 = FUN_00038cb0();\n  iVar4 = local_24 + *(int *)(param_2 + 0x10);\n  if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }\n  piVar2 = *(int **)(param_1 + 0x10);\n  if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }\n  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));\n  FUN_0001dd30(param_2);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }\n                    \n  FUN_0008eb20();\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int *piVar2;" (primitive_type "int") (pointer_declarator "*piVar2" (* "*") (identifier "piVar2")) (; ";")) (declaration "undefined4 uVar3;" (type_identifier "undefined4") (identifier "uVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "int iVar5;" (primitive_type "int") (identifier "iVar5") (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "undefined4 local_24;" (type_identifier "undefined4") (identifier "local_24") (; ";")) (expression_statement "iVar1 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "iVar1 = *(int *)(in_GS_OFFSET + 0x14)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (expression_statement "uVar3 = FUN_00038cb0();" (assignment_expression "uVar3 = FUN_00038cb0()" (identifier "uVar3") (= "=") (call_expression "FUN_00038cb0()" (identifier "FUN_00038cb0") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "iVar4 = local_24 + *(int *)(param_2 + 0x10);" (assignment_expression "iVar4 = local_24 + *(int *)(param_2 + 0x10)" (identifier "iVar4") (= "=") (binary_expression "local_24 + *(int *)(param_2 + 0x10)" (identifier "local_24") (+ "+") (pointer_expression "*(int *)(param_2 + 0x10)" (* "*") (cast_expression "(int *)(param_2 + 0x10)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x10)" (( "(") (binary_expression "param_2 + 0x10" (identifier "param_2") (+ "+") (number_literal "0x10")) () ")")))))) (; ";")) (if_statement "if (*(int *)(param_1 + 0x18) != 0) {\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0x18) != 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x18) != 0" (pointer_expression "*(int *)(param_1 + 0x18)" (* "*") (cast_expression "(int *)(param_1 + 0x18)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")")))) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);\n  }" ({ "{") (expression_statement "FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);" (call_expression "FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0)" (identifier "FUN_0001b790") (argument_list "(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0)" (( "(") (pointer_expression "*(int *)(param_1 + 0x18)" (* "*") (cast_expression "(int *)(param_1 + 0x18)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")")))) (, ",") (number_literal "1") (, ",") (number_literal "0xffffffff") (, ",") (number_literal "0") (, ",") (identifier "iVar4") (, ",") (identifier "uVar3") (, ",") (number_literal "0") (, ",") (number_literal "0") (, ",") (number_literal "0") (, ",") (number_literal "0") (, ",") (number_literal "0") () ")"))) (; ";")) (} "}"))) (expression_statement "piVar2 = *(int **)(param_1 + 0x10);" (assignment_expression "piVar2 = *(int **)(param_1 + 0x10)" (identifier "piVar2") (= "=") (pointer_expression "*(int **)(param_1 + 0x10)" (* "*") (cast_expression "(int **)(param_1 + 0x10)" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")"))))) (; ";")) (if_statement "if (piVar2 != (int *)0x0) {\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }" (if "if") (parenthesized_expression "(piVar2 != (int *)0x0)" (( "(") (binary_expression "piVar2 != (int *)0x0" (identifier "piVar2") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);\n    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }\n  }" ({ "{") (expression_statement "iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);" (assignment_expression "iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3)" (identifier "iVar4") (= "=") (call_expression "(**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3)" (parenthesized_expression "(**(code **)(*piVar2 + 8))" (( "(") (pointer_expression "**(code **)(*piVar2 + 8)" (* "*") (pointer_expression "*(code **)(*piVar2 + 8)" (* "*") (cast_expression "(code **)(*piVar2 + 8)" (( "(") (type_descriptor "code **" (type_identifier "code") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(*piVar2 + 8)" (( "(") (binary_expression "*piVar2 + 8" (pointer_expression "*piVar2" (* "*") (identifier "piVar2")) (+ "+") (number_literal "8")) () ")"))))) () ")")) (argument_list "(piVar2,iVar4,uVar3)" (( "(") (identifier "piVar2") (, ",") (identifier "iVar4") (, ",") (identifier "uVar3") () ")")))) (; ";")) (if_statement "if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }" (if "if") (parenthesized_expression "((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1))" (( "(") (binary_expression "(0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)" (parenthesized_expression "(0x8000 < iVar4)" (( "(") (binary_expression "0x8000 < iVar4" (number_literal "0x8000") (< "<") (identifier "iVar4")) () ")")) (&& "&&") (parenthesized_expression "(*(int *)(param_1 + 0x1a4) != 1)" (( "(") (binary_expression "*(int *)(param_1 + 0x1a4) != 1" (pointer_expression "*(int *)(param_1 + 0x1a4)" (* "*") (cast_expression "(int *)(param_1 + 0x1a4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x1a4)" (( "(") (binary_expression "param_1 + 0x1a4" (identifier "param_1") (+ "+") (number_literal "0x1a4")) () ")")))) (!= "!=") (number_literal "1")) () ")"))) () ")")) (compound_statement "{\n      *(int *)(param_1 + 0x1a0) = iVar4;\n      iVar4 = *(int *)(param_1 + 0x124);\n      *(undefined4 *)(param_1 + 0x1a4) = 1;\n      if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }\n    }" ({ "{") (expression_statement "*(int *)(param_1 + 0x1a0) = iVar4;" (assignment_expression "*(int *)(param_1 + 0x1a0) = iVar4" (pointer_expression "*(int *)(param_1 + 0x1a0)" (* "*") (cast_expression "(int *)(param_1 + 0x1a0)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x1a0)" (( "(") (binary_expression "param_1 + 0x1a0" (identifier "param_1") (+ "+") (number_literal "0x1a0")) () ")")))) (= "=") (identifier "iVar4")) (; ";")) (expression_statement "iVar4 = *(int *)(param_1 + 0x124);" (assignment_expression "iVar4 = *(int *)(param_1 + 0x124)" (identifier "iVar4") (= "=") (pointer_expression "*(int *)(param_1 + 0x124)" (* "*") (cast_expression "(int *)(param_1 + 0x124)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x124)" (( "(") (binary_expression "param_1 + 0x124" (identifier "param_1") (+ "+") (number_literal "0x124")) () ")"))))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x1a4) = 1;" (assignment_expression "*(undefined4 *)(param_1 + 0x1a4) = 1" (pointer_expression "*(undefined4 *)(param_1 + 0x1a4)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x1a4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x1a4)" (( "(") (binary_expression "param_1 + 0x1a4" (identifier "param_1") (+ "+") (number_literal "0x1a4")) () ")")))) (= "=") (number_literal "1")) (; ";")) (if_statement "if (iVar4 != 0) {\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }" (if "if") (parenthesized_expression "(iVar4 != 0)" (( "(") (binary_expression "iVar4 != 0" (identifier "iVar4") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        iVar5 = 0;\n        while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }\n      }" ({ "{") (expression_statement "iVar5 = 0;" (assignment_expression "iVar5 = 0" (identifier "iVar5") (= "=") (number_literal "0")) (; ";")) (while_statement "while( true ) {\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n          iVar4 = FUN_00081c90(iVar4,iVar5);\n          if (iVar4 == 0) break;\n          if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          iVar4 = *(int *)(param_1 + 0x124);\n          iVar5 = iVar5 + 1;\n        }" ({ "{") (expression_statement "iVar4 = FUN_00081c90(iVar4,iVar5);" (assignment_expression "iVar4 = FUN_00081c90(iVar4,iVar5)" (identifier "iVar4") (= "=") (call_expression "FUN_00081c90(iVar4,iVar5)" (identifier "FUN_00081c90") (argument_list "(iVar4,iVar5)" (( "(") (identifier "iVar4") (, ",") (identifier "iVar5") () ")")))) (; ";")) (if_statement "if (iVar4 == 0) break;" (if "if") (parenthesized_expression "(iVar4 == 0)" (( "(") (binary_expression "iVar4 == 0" (identifier "iVar4") (== "==") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (if_statement "if (*(int *)(iVar4 + 0xc) == 1) {\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }\n          else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" (if "if") (parenthesized_expression "(*(int *)(iVar4 + 0xc) == 1)" (( "(") (binary_expression "*(int *)(iVar4 + 0xc) == 1" (pointer_expression "*(int *)(iVar4 + 0xc)" (* "*") (cast_expression "(int *)(iVar4 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0xc)" (( "(") (binary_expression "iVar4 + 0xc" (identifier "iVar4") (+ "+") (number_literal "0xc")) () ")")))) (== "==") (number_literal "1")) () ")")) (compound_statement "{\n            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" ({ "{") (expression_statement "FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);" (call_expression "FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1)" (identifier "FUN_0008daf0") (argument_list "(*(undefined4 *)(iVar4 + 0x4c),1)" (( "(") (pointer_expression "*(undefined4 *)(iVar4 + 0x4c)" (* "*") (cast_expression "(undefined4 *)(iVar4 + 0x4c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x4c)" (( "(") (binary_expression "iVar4 + 0x4c" (identifier "iVar4") (+ "+") (number_literal "0x4c")) () ")")))) (, ",") (number_literal "1") () ")"))) (; ";")) (} "}")) (else_clause "else if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" (else "else") (if_statement "if (*(int *)(iVar4 + 0xc) == 3) {\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" (if "if") (parenthesized_expression "(*(int *)(iVar4 + 0xc) == 3)" (( "(") (binary_expression "*(int *)(iVar4 + 0xc) == 3" (pointer_expression "*(int *)(iVar4 + 0xc)" (* "*") (cast_expression "(int *)(iVar4 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0xc)" (( "(") (binary_expression "iVar4 + 0xc" (identifier "iVar4") (+ "+") (number_literal "0xc")) () ")")))) (== "==") (number_literal "3")) () ")")) (compound_statement "{\n            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);\n          }" ({ "{") (expression_statement "FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);" (call_expression "FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1)" (identifier "FUN_0001f630") (argument_list "(*(undefined4 *)(iVar4 + 0x4c),1)" (( "(") (pointer_expression "*(undefined4 *)(iVar4 + 0x4c)" (* "*") (cast_expression "(undefined4 *)(iVar4 + 0x4c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x4c)" (( "(") (binary_expression "iVar4 + 0x4c" (identifier "iVar4") (+ "+") (number_literal "0x4c")) () ")")))) (, ",") (number_literal "1") () ")"))) (; ";")) (} "}"))))) (expression_statement "iVar4 = *(int *)(param_1 + 0x124);" (assignment_expression "iVar4 = *(int *)(param_1 + 0x124)" (identifier "iVar4") (= "=") (pointer_expression "*(int *)(param_1 + 0x124)" (* "*") (cast_expression "(int *)(param_1 + 0x124)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x124)" (( "(") (binary_expression "param_1 + 0x124" (identifier "param_1") (+ "+") (number_literal "0x124")) () ")"))))) (; ";")) (expression_statement "iVar5 = iVar5 + 1;" (assignment_expression "iVar5 = iVar5 + 1" (identifier "iVar5") (= "=") (binary_expression "iVar5 + 1" (identifier "iVar5") (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (} "}"))) (} "}"))) (} "}"))) (expression_statement "FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));" (call_expression "FUN_0001dd30(*(undefined4 *)(param_2 + 0x10))" (identifier "FUN_0001dd30") (argument_list "(*(undefined4 *)(param_2 + 0x10))" (( "(") (pointer_expression "*(undefined4 *)(param_2 + 0x10)" (* "*") (cast_expression "(undefined4 *)(param_2 + 0x10)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x10)" (( "(") (binary_expression "param_2 + 0x10" (identifier "param_2") (+ "+") (number_literal "0x10")) () ")")))) () ")"))) (; ";")) (expression_statement "FUN_0001dd30(param_2);" (call_expression "FUN_0001dd30(param_2)" (identifier "FUN_0001dd30") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")"))) (; ";")) (if_statement "if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return;\n  }" (if "if") (parenthesized_expression "(iVar1 == *(int *)(in_GS_OFFSET + 0x14))" (( "(") (binary_expression "iVar1 == *(int *)(in_GS_OFFSET + 0x14)" (identifier "iVar1") (== "==") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n    return;\n  }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "FUN_0008eb20();" (call_expression "FUN_0008eb20()" (identifier "FUN_0008eb20") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Enum "anon_enum_32": Some values do not have unique names */

void __regparm3 function_1(type_1 ssh,type_2 *pkt)

{
  type_3 *var_4;
  type_4 var_6;
  int var_7;
  type_5 *var_8;
  void *var_10;
  int var_1;
  int var_5;
  int var_14;
  type_6 uStack_14;
  
  uStack_14 = 0x3a54d;
  var_14 = *(int *)(var_1 + 0x14);
  var_7 = var_2(ssh,pkt,&var_5);
  var_4 = pkt->data;
  if (ssh->logctx != (void *)0x0) {
    var_3(ssh->logctx,1,-1,(char *)0x0,var_4 + var_5,var_7,0,(type_7 *)0x0,(type_8 *)0x0,0
               ,(char *)0x0);
  }
  var_6 = ssh->s;
  if (var_6 != (type_4)0x0) {
    var_7 = (*(*var_6)->write)(var_6,(char *)(var_4 + var_5),var_7);
    if ((0x8000 < var_7) && (ssh->throttled_all != 1)) {
      ssh->overall_bufsize = var_7;
      var_8 = ssh->channels;
      ssh->throttled_all = 1;
      if (var_8 != (type_5 *)0x0) {
        var_7 = 0;
        while( true ) {
          var_10 = var_9(var_8,var_7);
          if (var_10 == (void *)0x0) break;
          if (*(int *)((int)var_10 + 0xc) == 1) {
            var_11(*(type_9 **)((int)var_10 + 0x4c),1);
          }
          else if (*(int *)((int)var_10 + 0xc) == 3) {
            var_12(*(type_10 **)((int)var_10 + 0x4c),1);
          }
          var_8 = ssh->channels;
          var_7 = var_7 + 1;
        }
      }
    }
  }
  var_13(pkt->data);
  var_13(pkt);
  if (var_14 == *(int *)(var_1 + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  var_15();
}


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

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

void __regparm3 MASKED(int param_1,int param_2)

{
  int iVar1;
  int *piVar2;
  undefined4 uVar3;
  int iVar4;
  int iVar5;
  int in_GS_OFFSET;
  undefined4 local_24;
  
  iVar1 = *(int *)(in_GS_OFFSET + 0x14);
  uVar3 = FUN_00038cb0();
  iVar4 = local_24 + *(int *)(param_2 + 0x10);
  if (*(int *)(param_1 + 0x18) != 0) {
    FUN_0001b790(*(int *)(param_1 + 0x18),1,0xffffffff,0,iVar4,uVar3,0,0,0,0,0);
  }
  piVar2 = *(int **)(param_1 + 0x10);
  if (piVar2 != (int *)0x0) {
    iVar4 = (**(code **)(*piVar2 + 8))(piVar2,iVar4,uVar3);
    if ((0x8000 < iVar4) && (*(int *)(param_1 + 0x1a4) != 1)) {
      *(int *)(param_1 + 0x1a0) = iVar4;
      iVar4 = *(int *)(param_1 + 0x124);
      *(undefined4 *)(param_1 + 0x1a4) = 1;
      if (iVar4 != 0) {
        iVar5 = 0;
        while( true ) {
          iVar4 = FUN_00081c90(iVar4,iVar5);
          if (iVar4 == 0) break;
          if (*(int *)(iVar4 + 0xc) == 1) {
            FUN_0008daf0(*(undefined4 *)(iVar4 + 0x4c),1);
          }
          else if (*(int *)(iVar4 + 0xc) == 3) {
            FUN_0001f630(*(undefined4 *)(iVar4 + 0x4c),1);
          }
          iVar4 = *(int *)(param_1 + 0x124);
          iVar5 = iVar5 + 1;
        }
      }
    }
  }
  FUN_0001dd30(*(undefined4 *)(param_2 + 0x10));
  FUN_0001dd30(param_2);
  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  FUN_0008eb20();
}

