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

void pollwrap_free(pollwrapper *pw)

{
  void *ptr;
  
  pw->nfd = 0;
  while( true ) {
    ptr = delpos234(pw->fdtopos,0);
    if (ptr == (void *)0x0) break;
    safefree(ptr);
  }
  freetree234(pw->fdtopos);
  safefree(pw->fds);
  safefree(pw);
  return;
}



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

void FUN_000bdc60(undefined4 *param_1)

{
  int iVar1;
  
  param_1[1] = 0;
  while( true ) {
    iVar1 = FUN_0009eef0(param_1[3],0);
    if (iVar1 == 0) break;
    FUN_00032b40(iVar1);
  }
  FUN_0009b200(param_1[3]);
  FUN_00032b40(*param_1);
  FUN_00032b40(param_1);
  return;
}


PUSH ESI
PUSH EBX
CALL 0x0001c520
ADD EBX,0x7cae9
SUB ESP,0x4
MOV ESI,dword ptr [ESP + 0x10]
MOV dword ptr [ESI + 0x4],0x0
JMP 0x000bdc8c
SUB ESP,0xc
PUSH EAX
CALL 0x00032b40
ADD ESP,0x10
SUB ESP,0x8
PUSH 0x0
PUSH dword ptr [ESI + 0xc]
CALL 0x0009eef0
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x000bdc80
SUB ESP,0xc
PUSH dword ptr [ESI + 0xc]
CALL 0x0009b200
POP EAX
PUSH dword ptr [ESI]
CALL 0x00032b40
MOV dword ptr [ESP],ESI
CALL 0x00032b40
ADD ESP,0x14
POP EBX
POP ESI
RET
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid FUN_000bdc60(undefined4 *param_1)\n\n{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}\n\n" comment (function_definition "void FUN_000bdc60(undefined4 *param_1)\n\n{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}" primitive_type (function_declarator "FUN_000bdc60(undefined4 *param_1)" identifier (parameter_list "(undefined4 *param_1)" ( (parameter_declaration "undefined4 *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (expression_statement "param_1[1] = 0;" (assignment_expression "param_1[1] = 0" (subscript_expression "param_1[1]" identifier [ number_literal ]) = number_literal) ;) (while_statement "while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }" { (expression_statement "iVar1 = FUN_0009eef0(param_1[3],0);" (assignment_expression "iVar1 = FUN_0009eef0(param_1[3],0)" identifier = (call_expression "FUN_0009eef0(param_1[3],0)" identifier (argument_list "(param_1[3],0)" ( (subscript_expression "param_1[3]" identifier [ number_literal ]) , number_literal )))) ;) (if_statement "if (iVar1 == 0) break;" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "FUN_00032b40(iVar1);" (call_expression "FUN_00032b40(iVar1)" identifier (argument_list "(iVar1)" ( identifier ))) ;) })) (expression_statement "FUN_0009b200(param_1[3]);" (call_expression "FUN_0009b200(param_1[3])" identifier (argument_list "(param_1[3])" ( (subscript_expression "param_1[3]" identifier [ number_literal ]) ))) ;) (expression_statement "FUN_00032b40(*param_1);" (call_expression "FUN_00032b40(*param_1)" identifier (argument_list "(*param_1)" ( (pointer_expression "*param_1" * identifier) ))) ;) (expression_statement "FUN_00032b40(param_1);" (call_expression "FUN_00032b40(param_1)" identifier (argument_list "(param_1)" ( 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 pollwrap_free(pollwrapper *pw)\n\n{\n  void *ptr;\n  \n  pw->nfd = 0;\n  while( true ) {\n    ptr = delpos234(pw->fdtopos,0);\n    if (ptr == (void *)0x0) break;\n    safefree(ptr);\n  }\n  freetree234(pw->fdtopos);\n  safefree(pw->fds);\n  safefree(pw);\n  return;\n}\n\n" comment comment (function_definition "void pollwrap_free(pollwrapper *pw)\n\n{\n  void *ptr;\n  \n  pw->nfd = 0;\n  while( true ) {\n    ptr = delpos234(pw->fdtopos,0);\n    if (ptr == (void *)0x0) break;\n    safefree(ptr);\n  }\n  freetree234(pw->fdtopos);\n  safefree(pw->fds);\n  safefree(pw);\n  return;\n}" primitive_type (function_declarator "pollwrap_free(pollwrapper *pw)" identifier (parameter_list "(pollwrapper *pw)" ( (parameter_declaration "pollwrapper *pw" type_identifier (pointer_declarator "*pw" * identifier)) ))) (compound_statement "{\n  void *ptr;\n  \n  pw->nfd = 0;\n  while( true ) {\n    ptr = delpos234(pw->fdtopos,0);\n    if (ptr == (void *)0x0) break;\n    safefree(ptr);\n  }\n  freetree234(pw->fdtopos);\n  safefree(pw->fds);\n  safefree(pw);\n  return;\n}" { (declaration "void *ptr;" primitive_type (pointer_declarator "*ptr" * identifier) ;) (expression_statement "pw->nfd = 0;" (assignment_expression "pw->nfd = 0" (field_expression "pw->nfd" identifier -> field_identifier) = number_literal) ;) (while_statement "while( true ) {\n    ptr = delpos234(pw->fdtopos,0);\n    if (ptr == (void *)0x0) break;\n    safefree(ptr);\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    ptr = delpos234(pw->fdtopos,0);\n    if (ptr == (void *)0x0) break;\n    safefree(ptr);\n  }" { (expression_statement "ptr = delpos234(pw->fdtopos,0);" (assignment_expression "ptr = delpos234(pw->fdtopos,0)" identifier = (call_expression "delpos234(pw->fdtopos,0)" identifier (argument_list "(pw->fdtopos,0)" ( (field_expression "pw->fdtopos" identifier -> field_identifier) , number_literal )))) ;) (if_statement "if (ptr == (void *)0x0) break;" if (parenthesized_expression "(ptr == (void *)0x0)" ( (binary_expression "ptr == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (break_statement "break;" break ;)) (expression_statement "safefree(ptr);" (call_expression "safefree(ptr)" identifier (argument_list "(ptr)" ( identifier ))) ;) })) (expression_statement "freetree234(pw->fdtopos);" (call_expression "freetree234(pw->fdtopos)" identifier (argument_list "(pw->fdtopos)" ( (field_expression "pw->fdtopos" identifier -> field_identifier) ))) ;) (expression_statement "safefree(pw->fds);" (call_expression "safefree(pw->fds)" identifier (argument_list "(pw->fds)" ( (field_expression "pw->fds" identifier -> field_identifier) ))) ;) (expression_statement "safefree(pw);" (call_expression "safefree(pw)" identifier (argument_list "(pw)" ( identifier ))) ;) (return_statement "return;" return ;) })))
(translation_unit "void FUN_000bdc60(undefined4 *param_1)\n\n{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}\n\n" (function_definition "void FUN_000bdc60(undefined4 *param_1)\n\n{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}" primitive_type (function_declarator "FUN_000bdc60(undefined4 *param_1)" identifier (parameter_list "(undefined4 *param_1)" ( (parameter_declaration "undefined4 *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (expression_statement "param_1[1] = 0;" (assignment_expression "param_1[1] = 0" (subscript_expression "param_1[1]" identifier [ number_literal ]) = number_literal) ;) (while_statement "while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }" { (expression_statement "iVar1 = FUN_0009eef0(param_1[3],0);" (assignment_expression "iVar1 = FUN_0009eef0(param_1[3],0)" identifier = (call_expression "FUN_0009eef0(param_1[3],0)" identifier (argument_list "(param_1[3],0)" ( (subscript_expression "param_1[3]" identifier [ number_literal ]) , number_literal )))) ;) (if_statement "if (iVar1 == 0) break;" if (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "FUN_00032b40(iVar1);" (call_expression "FUN_00032b40(iVar1)" identifier (argument_list "(iVar1)" ( identifier ))) ;) })) (expression_statement "FUN_0009b200(param_1[3]);" (call_expression "FUN_0009b200(param_1[3])" identifier (argument_list "(param_1[3])" ( (subscript_expression "param_1[3]" identifier [ number_literal ]) ))) ;) (expression_statement "FUN_00032b40(*param_1);" (call_expression "FUN_00032b40(*param_1)" identifier (argument_list "(*param_1)" ( (pointer_expression "*param_1" * identifier) ))) ;) (expression_statement "FUN_00032b40(param_1);" (call_expression "FUN_00032b40(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (break_statement break ;)) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) })) (expression_statement (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) ))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * IDENT) ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (return_statement return ;) })))
(function_definition "void FUN_000bdc60(undefined4 *param_1)\n\n{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}" (primitive_type "void") (function_declarator "FUN_000bdc60(undefined4 *param_1)" (identifier "FUN_000bdc60") (parameter_list "(undefined4 *param_1)" (( "(") (parameter_declaration "undefined4 *param_1" (type_identifier "undefined4") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) () ")"))) (compound_statement "{\n  int iVar1;\n  \n  param_1[1] = 0;\n  while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }\n  FUN_0009b200(param_1[3]);\n  FUN_00032b40(*param_1);\n  FUN_00032b40(param_1);\n  return;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (expression_statement "param_1[1] = 0;" (assignment_expression "param_1[1] = 0" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0")) (; ";")) (while_statement "while( true ) {\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n    iVar1 = FUN_0009eef0(param_1[3],0);\n    if (iVar1 == 0) break;\n    FUN_00032b40(iVar1);\n  }" ({ "{") (expression_statement "iVar1 = FUN_0009eef0(param_1[3],0);" (assignment_expression "iVar1 = FUN_0009eef0(param_1[3],0)" (identifier "iVar1") (= "=") (call_expression "FUN_0009eef0(param_1[3],0)" (identifier "FUN_0009eef0") (argument_list "(param_1[3],0)" (( "(") (subscript_expression "param_1[3]" (identifier "param_1") ([ "[") (number_literal "3") (] "]")) (, ",") (number_literal "0") () ")")))) (; ";")) (if_statement "if (iVar1 == 0) break;" (if "if") (parenthesized_expression "(iVar1 == 0)" (( "(") (binary_expression "iVar1 == 0" (identifier "iVar1") (== "==") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "FUN_00032b40(iVar1);" (call_expression "FUN_00032b40(iVar1)" (identifier "FUN_00032b40") (argument_list "(iVar1)" (( "(") (identifier "iVar1") () ")"))) (; ";")) (} "}"))) (expression_statement "FUN_0009b200(param_1[3]);" (call_expression "FUN_0009b200(param_1[3])" (identifier "FUN_0009b200") (argument_list "(param_1[3])" (( "(") (subscript_expression "param_1[3]" (identifier "param_1") ([ "[") (number_literal "3") (] "]")) () ")"))) (; ";")) (expression_statement "FUN_00032b40(*param_1);" (call_expression "FUN_00032b40(*param_1)" (identifier "FUN_00032b40") (argument_list "(*param_1)" (( "(") (pointer_expression "*param_1" (* "*") (identifier "param_1")) () ")"))) (; ";")) (expression_statement "FUN_00032b40(param_1);" (call_expression "FUN_00032b40(param_1)" (identifier "FUN_00032b40") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (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(type_1 *pw)

{
  void *var_2;
  
  pw->nfd = 0;
  while( true ) {
    var_2 = var_1(pw->fdtopos,0);
    if (var_2 == (void *)0x0) break;
    var_3(var_2);
  }
  var_4(pw->fdtopos);
  var_3(pw->fds);
  var_3(pw);
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) 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 (subscript_expression argument: (identifier) index: (number_literal)) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (subscript_expression argument: (identifier) index: (number_literal))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (return_statement))))

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

void MASKED(undefined4 *param_1)

{
  int iVar1;
  
  param_1[1] = 0;
  while( true ) {
    iVar1 = FUN_0009eef0(param_1[3],0);
    if (iVar1 == 0) break;
    FUN_00032b40(iVar1);
  }
  FUN_0009b200(param_1[3]);
  FUN_00032b40(*param_1);
  FUN_00032b40(param_1);
  return;
}

