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

void delete_callbacks_for_context(void *ctx)

{
  callback *ptr;
  callback *pcVar1;
  callback *pcVar2;
  callback *pcVar3;
  callback *pcVar4;
  
  pcVar3 = (callback *)0x0;
  pcVar1 = (callback *)0x0;
  if (cbhead != (callback *)0x0) {
    ptr = cbhead;
    pcVar2 = (callback *)0x0;
    pcVar4 = pcVar3;
    do {
      cbhead = ptr->next;
      if (ptr->ctx == ctx) {
        safefree(ptr);
        pcVar1 = pcVar2;
        pcVar3 = pcVar4;
      }
      else {
        pcVar1 = ptr;
        pcVar3 = ptr;
        if (pcVar4 != (callback *)0x0) {
          pcVar2->next = ptr;
          pcVar3 = pcVar4;
        }
      }
      ptr = cbhead;
      pcVar2 = pcVar1;
      pcVar4 = pcVar3;
    } while (cbhead != (callback *)0x0);
  }
  cbhead = pcVar3;
  cbtail = pcVar1;
  return;
}



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

void FUN_00014e20(int param_1)

{
  undefined4 *puVar1;
  undefined4 *puVar2;
  undefined4 *puVar3;
  undefined4 *puVar4;
  undefined4 *puVar5;
  
  puVar4 = (undefined4 *)0x0;
  puVar2 = (undefined4 *)0x0;
  if (DAT_000aa394 != (undefined4 *)0x0) {
    puVar1 = DAT_000aa394;
    puVar3 = (undefined4 *)0x0;
    puVar5 = puVar4;
    do {
      DAT_000aa394 = (undefined4 *)*puVar1;
      if (puVar1[2] == param_1) {
        FUN_0001b240(puVar1);
        puVar2 = puVar3;
        puVar4 = puVar5;
      }
      else {
        puVar2 = puVar1;
        puVar4 = puVar1;
        if (puVar5 != (undefined4 *)0x0) {
          *puVar3 = puVar1;
          puVar4 = puVar5;
        }
      }
      puVar1 = DAT_000aa394;
      puVar3 = puVar2;
      puVar5 = puVar4;
    } while (DAT_000aa394 != (undefined4 *)0x0);
  }
  DAT_000aa394 = puVar4;
  DAT_000aa390 = puVar2;
  return;
}


PUSH EBP
PUSH EDI
XOR EDI,EDI
PUSH ESI
XOR ESI,ESI
PUSH EBX
CALL 0x00014970
ADD EBX,0x94f63
SUB ESP,0xc
MOV EBP,dword ptr [ESP + 0x20]
MOV EAX,dword ptr [EBX + 0x604]
TEST EAX,EAX
JZ 0x00014e63
LEA ESI,[ESI]
MOV EDX,dword ptr [EAX]
MOV dword ptr [EBX + 0x604],EDX
CMP dword ptr [EAX + 0x8],EBP
JZ 0x00014e90
TEST EDI,EDI
JZ 0x00014e80
MOV dword ptr [ESI],EAX
MOV ESI,EAX
MOV EAX,EDX
TEST EAX,EAX
JNZ 0x00014e48
MOV dword ptr [EBX + 0x604],EDI
MOV dword ptr [EBX + 0x600],ESI
ADD ESP,0xc
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV ESI,EAX
MOV EDI,EAX
MOV EAX,EDX
JMP 0x00014e5f
SUB ESP,0xc
PUSH EAX
CALL 0x0001b240
MOV EDX,dword ptr [EBX + 0x604]
ADD ESP,0x10
MOV EAX,EDX
JMP 0x00014e5f
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_00014e20(int param_1)\n\n{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}\n\n" comment (function_definition "void FUN_00014e20(int param_1)\n\n{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}" primitive_type (function_declarator "FUN_00014e20(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}" { (declaration "undefined4 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "undefined4 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined4 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "undefined4 *puVar4;" type_identifier (pointer_declarator "*puVar4" * identifier) ;) (declaration "undefined4 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (expression_statement "puVar4 = (undefined4 *)0x0;" (assignment_expression "puVar4 = (undefined4 *)0x0" identifier = (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "puVar2 = (undefined4 *)0x0;" (assignment_expression "puVar2 = (undefined4 *)0x0" identifier = (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (if_statement "if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }" if (parenthesized_expression "(DAT_000aa394 != (undefined4 *)0x0)" ( (binary_expression "DAT_000aa394 != (undefined4 *)0x0" identifier != (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }" { (expression_statement "puVar1 = DAT_000aa394;" (assignment_expression "puVar1 = DAT_000aa394" identifier = identifier) ;) (expression_statement "puVar3 = (undefined4 *)0x0;" (assignment_expression "puVar3 = (undefined4 *)0x0" identifier = (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "puVar5 = puVar4;" (assignment_expression "puVar5 = puVar4" identifier = identifier) ;) (do_statement "do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);" do (compound_statement "{\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    }" { (expression_statement "DAT_000aa394 = (undefined4 *)*puVar1;" (assignment_expression "DAT_000aa394 = (undefined4 *)*puVar1" identifier = (cast_expression "(undefined4 *)*puVar1" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar1" * identifier))) ;) (if_statement "if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" if (parenthesized_expression "(puVar1[2] == param_1)" ( (binary_expression "puVar1[2] == param_1" (subscript_expression "puVar1[2]" identifier [ number_literal ]) == identifier) )) (compound_statement "{\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }" { (expression_statement "FUN_0001b240(puVar1);" (call_expression "FUN_0001b240(puVar1)" identifier (argument_list "(puVar1)" ( identifier ))) ;) (expression_statement "puVar2 = puVar3;" (assignment_expression "puVar2 = puVar3" identifier = identifier) ;) (expression_statement "puVar4 = puVar5;" (assignment_expression "puVar4 = puVar5" identifier = identifier) ;) }) (else_clause "else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" else (compound_statement "{\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" { (expression_statement "puVar2 = puVar1;" (assignment_expression "puVar2 = puVar1" identifier = identifier) ;) (expression_statement "puVar4 = puVar1;" (assignment_expression "puVar4 = puVar1" identifier = identifier) ;) (if_statement "if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }" if (parenthesized_expression "(puVar5 != (undefined4 *)0x0)" ( (binary_expression "puVar5 != (undefined4 *)0x0" identifier != (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }" { (expression_statement "*puVar3 = puVar1;" (assignment_expression "*puVar3 = puVar1" (pointer_expression "*puVar3" * identifier) = identifier) ;) (expression_statement "puVar4 = puVar5;" (assignment_expression "puVar4 = puVar5" identifier = identifier) ;) })) }))) (expression_statement "puVar1 = DAT_000aa394;" (assignment_expression "puVar1 = DAT_000aa394" identifier = identifier) ;) (expression_statement "puVar3 = puVar2;" (assignment_expression "puVar3 = puVar2" identifier = identifier) ;) (expression_statement "puVar5 = puVar4;" (assignment_expression "puVar5 = puVar4" identifier = identifier) ;) }) while (parenthesized_expression "(DAT_000aa394 != (undefined4 *)0x0)" ( (binary_expression "DAT_000aa394 != (undefined4 *)0x0" identifier != (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) })) (expression_statement "DAT_000aa394 = puVar4;" (assignment_expression "DAT_000aa394 = puVar4" identifier = identifier) ;) (expression_statement "DAT_000aa390 = puVar2;" (assignment_expression "DAT_000aa390 = puVar2" identifier = identifier) ;) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nvoid delete_callbacks_for_context(void *ctx)\n\n{\n  callback *ptr;\n  callback *pcVar1;\n  callback *pcVar2;\n  callback *pcVar3;\n  callback *pcVar4;\n  \n  pcVar3 = (callback *)0x0;\n  pcVar1 = (callback *)0x0;\n  if (cbhead != (callback *)0x0) {\n    ptr = cbhead;\n    pcVar2 = (callback *)0x0;\n    pcVar4 = pcVar3;\n    do {\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    } while (cbhead != (callback *)0x0);\n  }\n  cbhead = pcVar3;\n  cbtail = pcVar1;\n  return;\n}\n\n" comment comment (function_definition "void delete_callbacks_for_context(void *ctx)\n\n{\n  callback *ptr;\n  callback *pcVar1;\n  callback *pcVar2;\n  callback *pcVar3;\n  callback *pcVar4;\n  \n  pcVar3 = (callback *)0x0;\n  pcVar1 = (callback *)0x0;\n  if (cbhead != (callback *)0x0) {\n    ptr = cbhead;\n    pcVar2 = (callback *)0x0;\n    pcVar4 = pcVar3;\n    do {\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    } while (cbhead != (callback *)0x0);\n  }\n  cbhead = pcVar3;\n  cbtail = pcVar1;\n  return;\n}" primitive_type (function_declarator "delete_callbacks_for_context(void *ctx)" identifier (parameter_list "(void *ctx)" ( (parameter_declaration "void *ctx" primitive_type (pointer_declarator "*ctx" * identifier)) ))) (compound_statement "{\n  callback *ptr;\n  callback *pcVar1;\n  callback *pcVar2;\n  callback *pcVar3;\n  callback *pcVar4;\n  \n  pcVar3 = (callback *)0x0;\n  pcVar1 = (callback *)0x0;\n  if (cbhead != (callback *)0x0) {\n    ptr = cbhead;\n    pcVar2 = (callback *)0x0;\n    pcVar4 = pcVar3;\n    do {\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    } while (cbhead != (callback *)0x0);\n  }\n  cbhead = pcVar3;\n  cbtail = pcVar1;\n  return;\n}" { (declaration "callback *ptr;" type_identifier (pointer_declarator "*ptr" * identifier) ;) (declaration "callback *pcVar1;" type_identifier (pointer_declarator "*pcVar1" * identifier) ;) (declaration "callback *pcVar2;" type_identifier (pointer_declarator "*pcVar2" * identifier) ;) (declaration "callback *pcVar3;" type_identifier (pointer_declarator "*pcVar3" * identifier) ;) (declaration "callback *pcVar4;" type_identifier (pointer_declarator "*pcVar4" * identifier) ;) (expression_statement "pcVar3 = (callback *)0x0;" (assignment_expression "pcVar3 = (callback *)0x0" identifier = (cast_expression "(callback *)0x0" ( (type_descriptor "callback *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "pcVar1 = (callback *)0x0;" (assignment_expression "pcVar1 = (callback *)0x0" identifier = (cast_expression "(callback *)0x0" ( (type_descriptor "callback *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (if_statement "if (cbhead != (callback *)0x0) {\n    ptr = cbhead;\n    pcVar2 = (callback *)0x0;\n    pcVar4 = pcVar3;\n    do {\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    } while (cbhead != (callback *)0x0);\n  }" if (parenthesized_expression "(cbhead != (callback *)0x0)" ( (binary_expression "cbhead != (callback *)0x0" identifier != (cast_expression "(callback *)0x0" ( (type_descriptor "callback *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    ptr = cbhead;\n    pcVar2 = (callback *)0x0;\n    pcVar4 = pcVar3;\n    do {\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    } while (cbhead != (callback *)0x0);\n  }" { (expression_statement "ptr = cbhead;" (assignment_expression "ptr = cbhead" identifier = identifier) ;) (expression_statement "pcVar2 = (callback *)0x0;" (assignment_expression "pcVar2 = (callback *)0x0" identifier = (cast_expression "(callback *)0x0" ( (type_descriptor "callback *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "pcVar4 = pcVar3;" (assignment_expression "pcVar4 = pcVar3" identifier = identifier) ;) (do_statement "do {\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    } while (cbhead != (callback *)0x0);" do (compound_statement "{\n      cbhead = ptr->next;\n      if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }\n      ptr = cbhead;\n      pcVar2 = pcVar1;\n      pcVar4 = pcVar3;\n    }" { (expression_statement "cbhead = ptr->next;" (assignment_expression "cbhead = ptr->next" identifier = (field_expression "ptr->next" identifier -> field_identifier)) ;) (if_statement "if (ptr->ctx == ctx) {\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }\n      else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }" if (parenthesized_expression "(ptr->ctx == ctx)" ( (binary_expression "ptr->ctx == ctx" (field_expression "ptr->ctx" identifier -> field_identifier) == identifier) )) (compound_statement "{\n        safefree(ptr);\n        pcVar1 = pcVar2;\n        pcVar3 = pcVar4;\n      }" { (expression_statement "safefree(ptr);" (call_expression "safefree(ptr)" identifier (argument_list "(ptr)" ( identifier ))) ;) (expression_statement "pcVar1 = pcVar2;" (assignment_expression "pcVar1 = pcVar2" identifier = identifier) ;) (expression_statement "pcVar3 = pcVar4;" (assignment_expression "pcVar3 = pcVar4" identifier = identifier) ;) }) (else_clause "else {\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }" else (compound_statement "{\n        pcVar1 = ptr;\n        pcVar3 = ptr;\n        if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }\n      }" { (expression_statement "pcVar1 = ptr;" (assignment_expression "pcVar1 = ptr" identifier = identifier) ;) (expression_statement "pcVar3 = ptr;" (assignment_expression "pcVar3 = ptr" identifier = identifier) ;) (if_statement "if (pcVar4 != (callback *)0x0) {\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }" if (parenthesized_expression "(pcVar4 != (callback *)0x0)" ( (binary_expression "pcVar4 != (callback *)0x0" identifier != (cast_expression "(callback *)0x0" ( (type_descriptor "callback *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          pcVar2->next = ptr;\n          pcVar3 = pcVar4;\n        }" { (expression_statement "pcVar2->next = ptr;" (assignment_expression "pcVar2->next = ptr" (field_expression "pcVar2->next" identifier -> field_identifier) = identifier) ;) (expression_statement "pcVar3 = pcVar4;" (assignment_expression "pcVar3 = pcVar4" identifier = identifier) ;) })) }))) (expression_statement "ptr = cbhead;" (assignment_expression "ptr = cbhead" identifier = identifier) ;) (expression_statement "pcVar2 = pcVar1;" (assignment_expression "pcVar2 = pcVar1" identifier = identifier) ;) (expression_statement "pcVar4 = pcVar3;" (assignment_expression "pcVar4 = pcVar3" identifier = identifier) ;) }) while (parenthesized_expression "(cbhead != (callback *)0x0)" ( (binary_expression "cbhead != (callback *)0x0" identifier != (cast_expression "(callback *)0x0" ( (type_descriptor "callback *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) })) (expression_statement "cbhead = pcVar3;" (assignment_expression "cbhead = pcVar3" identifier = identifier) ;) (expression_statement "cbtail = pcVar1;" (assignment_expression "cbtail = pcVar1" identifier = identifier) ;) (return_statement "return;" return ;) })))
(translation_unit "void FUN_00014e20(int param_1)\n\n{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}\n\n" (function_definition "void FUN_00014e20(int param_1)\n\n{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}" primitive_type (function_declarator "FUN_00014e20(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}" { (declaration "undefined4 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "undefined4 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined4 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "undefined4 *puVar4;" type_identifier (pointer_declarator "*puVar4" * identifier) ;) (declaration "undefined4 *puVar5;" type_identifier (pointer_declarator "*puVar5" * identifier) ;) (expression_statement "puVar4 = (undefined4 *)0x0;" (assignment_expression "puVar4 = (undefined4 *)0x0" identifier = (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "puVar2 = (undefined4 *)0x0;" (assignment_expression "puVar2 = (undefined4 *)0x0" identifier = (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (if_statement "if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }" if (parenthesized_expression "(DAT_000aa394 != (undefined4 *)0x0)" ( (binary_expression "DAT_000aa394 != (undefined4 *)0x0" identifier != (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }" { (expression_statement "puVar1 = DAT_000aa394;" (assignment_expression "puVar1 = DAT_000aa394" identifier = identifier) ;) (expression_statement "puVar3 = (undefined4 *)0x0;" (assignment_expression "puVar3 = (undefined4 *)0x0" identifier = (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "puVar5 = puVar4;" (assignment_expression "puVar5 = puVar4" identifier = identifier) ;) (do_statement "do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);" do (compound_statement "{\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    }" { (expression_statement "DAT_000aa394 = (undefined4 *)*puVar1;" (assignment_expression "DAT_000aa394 = (undefined4 *)*puVar1" identifier = (cast_expression "(undefined4 *)*puVar1" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar1" * identifier))) ;) (if_statement "if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" if (parenthesized_expression "(puVar1[2] == param_1)" ( (binary_expression "puVar1[2] == param_1" (subscript_expression "puVar1[2]" identifier [ number_literal ]) == identifier) )) (compound_statement "{\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }" { (expression_statement "FUN_0001b240(puVar1);" (call_expression "FUN_0001b240(puVar1)" identifier (argument_list "(puVar1)" ( identifier ))) ;) (expression_statement "puVar2 = puVar3;" (assignment_expression "puVar2 = puVar3" identifier = identifier) ;) (expression_statement "puVar4 = puVar5;" (assignment_expression "puVar4 = puVar5" identifier = identifier) ;) }) (else_clause "else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" else (compound_statement "{\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" { (expression_statement "puVar2 = puVar1;" (assignment_expression "puVar2 = puVar1" identifier = identifier) ;) (expression_statement "puVar4 = puVar1;" (assignment_expression "puVar4 = puVar1" identifier = identifier) ;) (if_statement "if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }" if (parenthesized_expression "(puVar5 != (undefined4 *)0x0)" ( (binary_expression "puVar5 != (undefined4 *)0x0" identifier != (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }" { (expression_statement "*puVar3 = puVar1;" (assignment_expression "*puVar3 = puVar1" (pointer_expression "*puVar3" * identifier) = identifier) ;) (expression_statement "puVar4 = puVar5;" (assignment_expression "puVar4 = puVar5" identifier = identifier) ;) })) }))) (expression_statement "puVar1 = DAT_000aa394;" (assignment_expression "puVar1 = DAT_000aa394" identifier = identifier) ;) (expression_statement "puVar3 = puVar2;" (assignment_expression "puVar3 = puVar2" identifier = identifier) ;) (expression_statement "puVar5 = puVar4;" (assignment_expression "puVar5 = puVar4" identifier = identifier) ;) }) while (parenthesized_expression "(DAT_000aa394 != (undefined4 *)0x0)" ( (binary_expression "DAT_000aa394 != (undefined4 *)0x0" identifier != (cast_expression "(undefined4 *)0x0" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) })) (expression_statement "DAT_000aa394 = puVar4;" (assignment_expression "DAT_000aa394 = puVar4" identifier = identifier) ;) (expression_statement "DAT_000aa390 = puVar2;" (assignment_expression "DAT_000aa390 = puVar2" identifier = identifier) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) 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 = IDENT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == IDENT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) }))) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) ;) })) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (return_statement return ;) })))
(function_definition "void FUN_00014e20(int param_1)\n\n{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}" (primitive_type "void") (function_declarator "FUN_00014e20(int param_1)" (identifier "FUN_00014e20") (parameter_list "(int param_1)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) () ")"))) (compound_statement "{\n  undefined4 *puVar1;\n  undefined4 *puVar2;\n  undefined4 *puVar3;\n  undefined4 *puVar4;\n  undefined4 *puVar5;\n  \n  puVar4 = (undefined4 *)0x0;\n  puVar2 = (undefined4 *)0x0;\n  if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }\n  DAT_000aa394 = puVar4;\n  DAT_000aa390 = puVar2;\n  return;\n}" ({ "{") (declaration "undefined4 *puVar1;" (type_identifier "undefined4") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (declaration "undefined4 *puVar2;" (type_identifier "undefined4") (pointer_declarator "*puVar2" (* "*") (identifier "puVar2")) (; ";")) (declaration "undefined4 *puVar3;" (type_identifier "undefined4") (pointer_declarator "*puVar3" (* "*") (identifier "puVar3")) (; ";")) (declaration "undefined4 *puVar4;" (type_identifier "undefined4") (pointer_declarator "*puVar4" (* "*") (identifier "puVar4")) (; ";")) (declaration "undefined4 *puVar5;" (type_identifier "undefined4") (pointer_declarator "*puVar5" (* "*") (identifier "puVar5")) (; ";")) (expression_statement "puVar4 = (undefined4 *)0x0;" (assignment_expression "puVar4 = (undefined4 *)0x0" (identifier "puVar4") (= "=") (cast_expression "(undefined4 *)0x0" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "puVar2 = (undefined4 *)0x0;" (assignment_expression "puVar2 = (undefined4 *)0x0" (identifier "puVar2") (= "=") (cast_expression "(undefined4 *)0x0" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (if_statement "if (DAT_000aa394 != (undefined4 *)0x0) {\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }" (if "if") (parenthesized_expression "(DAT_000aa394 != (undefined4 *)0x0)" (( "(") (binary_expression "DAT_000aa394 != (undefined4 *)0x0" (identifier "DAT_000aa394") (!= "!=") (cast_expression "(undefined4 *)0x0" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    puVar1 = DAT_000aa394;\n    puVar3 = (undefined4 *)0x0;\n    puVar5 = puVar4;\n    do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);\n  }" ({ "{") (expression_statement "puVar1 = DAT_000aa394;" (assignment_expression "puVar1 = DAT_000aa394" (identifier "puVar1") (= "=") (identifier "DAT_000aa394")) (; ";")) (expression_statement "puVar3 = (undefined4 *)0x0;" (assignment_expression "puVar3 = (undefined4 *)0x0" (identifier "puVar3") (= "=") (cast_expression "(undefined4 *)0x0" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "puVar5 = puVar4;" (assignment_expression "puVar5 = puVar4" (identifier "puVar5") (= "=") (identifier "puVar4")) (; ";")) (do_statement "do {\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    } while (DAT_000aa394 != (undefined4 *)0x0);" (do "do") (compound_statement "{\n      DAT_000aa394 = (undefined4 *)*puVar1;\n      if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }\n      puVar1 = DAT_000aa394;\n      puVar3 = puVar2;\n      puVar5 = puVar4;\n    }" ({ "{") (expression_statement "DAT_000aa394 = (undefined4 *)*puVar1;" (assignment_expression "DAT_000aa394 = (undefined4 *)*puVar1" (identifier "DAT_000aa394") (= "=") (cast_expression "(undefined4 *)*puVar1" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*puVar1" (* "*") (identifier "puVar1")))) (; ";")) (if_statement "if (puVar1[2] == param_1) {\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }\n      else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" (if "if") (parenthesized_expression "(puVar1[2] == param_1)" (( "(") (binary_expression "puVar1[2] == param_1" (subscript_expression "puVar1[2]" (identifier "puVar1") ([ "[") (number_literal "2") (] "]")) (== "==") (identifier "param_1")) () ")")) (compound_statement "{\n        FUN_0001b240(puVar1);\n        puVar2 = puVar3;\n        puVar4 = puVar5;\n      }" ({ "{") (expression_statement "FUN_0001b240(puVar1);" (call_expression "FUN_0001b240(puVar1)" (identifier "FUN_0001b240") (argument_list "(puVar1)" (( "(") (identifier "puVar1") () ")"))) (; ";")) (expression_statement "puVar2 = puVar3;" (assignment_expression "puVar2 = puVar3" (identifier "puVar2") (= "=") (identifier "puVar3")) (; ";")) (expression_statement "puVar4 = puVar5;" (assignment_expression "puVar4 = puVar5" (identifier "puVar4") (= "=") (identifier "puVar5")) (; ";")) (} "}")) (else_clause "else {\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" (else "else") (compound_statement "{\n        puVar2 = puVar1;\n        puVar4 = puVar1;\n        if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }\n      }" ({ "{") (expression_statement "puVar2 = puVar1;" (assignment_expression "puVar2 = puVar1" (identifier "puVar2") (= "=") (identifier "puVar1")) (; ";")) (expression_statement "puVar4 = puVar1;" (assignment_expression "puVar4 = puVar1" (identifier "puVar4") (= "=") (identifier "puVar1")) (; ";")) (if_statement "if (puVar5 != (undefined4 *)0x0) {\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }" (if "if") (parenthesized_expression "(puVar5 != (undefined4 *)0x0)" (( "(") (binary_expression "puVar5 != (undefined4 *)0x0" (identifier "puVar5") (!= "!=") (cast_expression "(undefined4 *)0x0" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n          *puVar3 = puVar1;\n          puVar4 = puVar5;\n        }" ({ "{") (expression_statement "*puVar3 = puVar1;" (assignment_expression "*puVar3 = puVar1" (pointer_expression "*puVar3" (* "*") (identifier "puVar3")) (= "=") (identifier "puVar1")) (; ";")) (expression_statement "puVar4 = puVar5;" (assignment_expression "puVar4 = puVar5" (identifier "puVar4") (= "=") (identifier "puVar5")) (; ";")) (} "}"))) (} "}")))) (expression_statement "puVar1 = DAT_000aa394;" (assignment_expression "puVar1 = DAT_000aa394" (identifier "puVar1") (= "=") (identifier "DAT_000aa394")) (; ";")) (expression_statement "puVar3 = puVar2;" (assignment_expression "puVar3 = puVar2" (identifier "puVar3") (= "=") (identifier "puVar2")) (; ";")) (expression_statement "puVar5 = puVar4;" (assignment_expression "puVar5 = puVar4" (identifier "puVar5") (= "=") (identifier "puVar4")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(DAT_000aa394 != (undefined4 *)0x0)" (( "(") (binary_expression "DAT_000aa394 != (undefined4 *)0x0" (identifier "DAT_000aa394") (!= "!=") (cast_expression "(undefined4 *)0x0" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (; ";")) (} "}"))) (expression_statement "DAT_000aa394 = puVar4;" (assignment_expression "DAT_000aa394 = puVar4" (identifier "DAT_000aa394") (= "=") (identifier "puVar4")) (; ";")) (expression_statement "DAT_000aa390 = puVar2;" (assignment_expression "DAT_000aa390 = puVar2" (identifier "DAT_000aa390") (= "=") (identifier "puVar2")) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

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

void function_1(void *var_2)

{
  type_1 *ptr;
  type_1 *pcVar1;
  type_1 *pcVar2;
  type_1 *pcVar3;
  type_1 *var_4;
  
  pcVar3 = (type_1 *)0x0;
  pcVar1 = (type_1 *)0x0;
  if (var_1 != (type_1 *)0x0) {
    ptr = var_1;
    pcVar2 = (type_1 *)0x0;
    var_4 = pcVar3;
    do {
      var_1 = ptr->next;
      if (ptr->var_2 == var_2) {
        var_3(ptr);
        pcVar1 = pcVar2;
        pcVar3 = var_4;
      }
      else {
        pcVar1 = ptr;
        pcVar3 = ptr;
        if (var_4 != (type_1 *)0x0) {
          pcVar2->next = ptr;
          pcVar3 = var_4;
        }
      }
      ptr = var_1;
      pcVar2 = pcVar1;
      var_4 = pcVar3;
    } while (var_1 != (type_1 *)0x0);
  }
  var_1 = pcVar3;
  cbtail = pcVar1;
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (do_statement body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (return_statement))))

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

void MASKED(int param_1)

{
  undefined4 *puVar1;
  undefined4 *puVar2;
  undefined4 *puVar3;
  undefined4 *puVar4;
  undefined4 *puVar5;
  
  puVar4 = (undefined4 *)0x0;
  puVar2 = (undefined4 *)0x0;
  if (DAT_000aa394 != (undefined4 *)0x0) {
    puVar1 = DAT_000aa394;
    puVar3 = (undefined4 *)0x0;
    puVar5 = puVar4;
    do {
      DAT_000aa394 = (undefined4 *)*puVar1;
      if (puVar1[2] == param_1) {
        FUN_0001b240(puVar1);
        puVar2 = puVar3;
        puVar4 = puVar5;
      }
      else {
        puVar2 = puVar1;
        puVar4 = puVar1;
        if (puVar5 != (undefined4 *)0x0) {
          *puVar3 = puVar1;
          puVar4 = puVar5;
        }
      }
      puVar1 = DAT_000aa394;
      puVar3 = puVar2;
      puVar5 = puVar4;
    } while (DAT_000aa394 != (undefined4 *)0x0);
  }
  DAT_000aa394 = puVar4;
  DAT_000aa390 = puVar2;
  return;
}

