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

int md5_stream(FILE *stream,void *resblock)

{
  size_t sVar1;
  int iVar2;
  uint len;
  md5_ctx ctx;
  char buffer [4168];
  
  md5_init_ctx(&ctx);
  do {
    len = 0;
    do {
      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);
      len = len + sVar1;
      if (0xfff < len) break;
    } while (sVar1 != 0);
    if (sVar1 == 0) {
      iVar2 = ferror((FILE *)stream);
      if (iVar2 == 0) {
        if (len != 0) {
          md5_process_bytes(buffer,len,&ctx);
        }
        md5_finish_ctx(&ctx,resblock);
        return 0;
      }
      return 1;
    }
    md5_process_block(buffer,0x1000,&ctx);
  } while( true );
}



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

undefined4 FUN_00068fe0(FILE *param_1,undefined4 param_2)

{
  size_t sVar1;
  int iVar2;
  uint uVar3;
  undefined1 local_1100 [156];
  undefined1 local_1064 [4176];
  undefined4 uStack_14;
  
  uStack_14 = 0x68fe9;
  FUN_00068420(local_1100);
  do {
    uVar3 = 0;
    do {
      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);
      uVar3 = uVar3 + sVar1;
      if (0xfff < uVar3) break;
    } while (sVar1 != 0);
    if (sVar1 == 0) {
      iVar2 = ferror(param_1);
      if (iVar2 == 0) {
        if (uVar3 != 0) {
          FUN_00068cb0(local_1064,uVar3,local_1100);
        }
        FUN_00068bf0(local_1100,param_2);
        return 0;
      }
      return 1;
    }
    FUN_00068490(local_1064,0x1000,local_1100);
  } while( true );
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00017b80
ADD EBX,0x166017
SUB ESP,0x1118
LEA EAX,[ESP + 0x28]
MOV EDI,dword ptr [ESP + 0x112c]
MOV dword ptr [ESP + 0x18],EAX
PUSH EAX
CALL 0x00068420
ADD ESP,0x10
LEA ESI,[ESP + 0xb8]
LEA ESI,[ESI]
XOR EBP,EBP
LEA ESI,[ESI]
MOV EAX,0x1000
PUSH EDI
SUB EAX,EBP
PUSH EAX
LEA EAX,[ESI + EBP*0x1]
PUSH 0x1
PUSH EAX
CALL 0x00016520
ADD ESP,0x10
ADD EBP,EAX
CMP EBP,0xfff
JA 0x00069045
TEST EAX,EAX
JNZ 0x00069020
TEST EAX,EAX
JZ 0x00069060
SUB ESP,0x4
PUSH dword ptr [ESP + 0x10]
PUSH 0x1000
PUSH ESI
CALL 0x00068490
ADD ESP,0x10
JMP 0x00069018
SUB ESP,0xc
PUSH EDI
CALL 0x00016260
ADD ESP,0x10
MOV EDI,EAX
TEST EAX,EAX
JNZ 0x00069099
TEST EBP,EBP
JNZ 0x000690ab
SUB ESP,0x8
PUSH dword ptr [ESP + 0x112c]
PUSH dword ptr [ESP + 0x18]
CALL 0x00068bf0
ADD ESP,0x10
MOV EAX,EDI
ADD ESP,0x110c
POP EBX
POP ESI
POP EDI
POP EBP
RET
ADD ESP,0x110c
MOV EDI,0x1
POP EBX
MOV EAX,EDI
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0x4
PUSH dword ptr [ESP + 0x10]
PUSH EBP
PUSH ESI
CALL 0x00068cb0
ADD ESP,0x10
JMP 0x00069076
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 FUN_00068fe0(FILE *param_1,undefined4 param_2)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}\n\n" comment (function_definition "undefined4 FUN_00068fe0(FILE *param_1,undefined4 param_2)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}" type_identifier (function_declarator "FUN_00068fe0(FILE *param_1,undefined4 param_2)" identifier (parameter_list "(FILE *param_1,undefined4 param_2)" ( (parameter_declaration "FILE *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined4 param_2" type_identifier identifier) ))) (compound_statement "{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "undefined1 local_1100 [156];" type_identifier (array_declarator "local_1100 [156]" identifier [ number_literal ]) ;) (declaration "undefined1 local_1064 [4176];" type_identifier (array_declarator "local_1064 [4176]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x68fe9;" (assignment_expression "uStack_14 = 0x68fe9" identifier = number_literal) ;) (expression_statement "FUN_00068420(local_1100);" (call_expression "FUN_00068420(local_1100)" identifier (argument_list "(local_1100)" ( identifier ))) ;) (do_statement "do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );" do (compound_statement "{\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  }" { (expression_statement "uVar3 = 0;" (assignment_expression "uVar3 = 0" identifier = number_literal) ;) (do_statement "do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);" do (compound_statement "{\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    }" { (expression_statement "sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);" (assignment_expression "sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" identifier = (call_expression "fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" identifier (argument_list "(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" ( (binary_expression "local_1064 + uVar3" identifier + identifier) , number_literal , (binary_expression "0x1000 - uVar3" number_literal - identifier) , identifier )))) ;) (expression_statement "uVar3 = uVar3 + sVar1;" (assignment_expression "uVar3 = uVar3 + sVar1" identifier = (binary_expression "uVar3 + sVar1" identifier + identifier)) ;) (if_statement "if (0xfff < uVar3) break;" if (parenthesized_expression "(0xfff < uVar3)" ( (binary_expression "0xfff < uVar3" number_literal < identifier) )) (break_statement "break;" break ;)) }) while (parenthesized_expression "(sVar1 != 0)" ( (binary_expression "sVar1 != 0" identifier != number_literal) )) ;) (if_statement "if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }" if (parenthesized_expression "(sVar1 == 0)" ( (binary_expression "sVar1 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }" { (expression_statement "iVar2 = ferror(param_1);" (assignment_expression "iVar2 = ferror(param_1)" identifier = (call_expression "ferror(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (if_statement "if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }" { (if_statement "if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }" if (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) (compound_statement "{\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }" { (expression_statement "FUN_00068cb0(local_1064,uVar3,local_1100);" (call_expression "FUN_00068cb0(local_1064,uVar3,local_1100)" identifier (argument_list "(local_1064,uVar3,local_1100)" ( identifier , identifier , identifier ))) ;) })) (expression_statement "FUN_00068bf0(local_1100,param_2);" (call_expression "FUN_00068bf0(local_1100,param_2)" identifier (argument_list "(local_1100,param_2)" ( identifier , identifier ))) ;) (return_statement "return 0;" return number_literal ;) })) (return_statement "return 1;" return number_literal ;) })) (expression_statement "FUN_00068490(local_1064,0x1000,local_1100);" (call_expression "FUN_00068490(local_1064,0x1000,local_1100)" identifier (argument_list "(local_1064,0x1000,local_1100)" ( identifier , number_literal , identifier ))) ;) }) while (parenthesized_expression "( true )" ( true )) ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nint md5_stream(FILE *stream,void *resblock)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint len;\n  md5_ctx ctx;\n  char buffer [4168];\n  \n  md5_init_ctx(&ctx);\n  do {\n    len = 0;\n    do {\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }\n    md5_process_block(buffer,0x1000,&ctx);\n  } while( true );\n}\n\n" comment comment (function_definition "int md5_stream(FILE *stream,void *resblock)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint len;\n  md5_ctx ctx;\n  char buffer [4168];\n  \n  md5_init_ctx(&ctx);\n  do {\n    len = 0;\n    do {\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }\n    md5_process_block(buffer,0x1000,&ctx);\n  } while( true );\n}" primitive_type (function_declarator "md5_stream(FILE *stream,void *resblock)" identifier (parameter_list "(FILE *stream,void *resblock)" ( (parameter_declaration "FILE *stream" type_identifier (pointer_declarator "*stream" * identifier)) , (parameter_declaration "void *resblock" primitive_type (pointer_declarator "*resblock" * identifier)) ))) (compound_statement "{\n  size_t sVar1;\n  int iVar2;\n  uint len;\n  md5_ctx ctx;\n  char buffer [4168];\n  \n  md5_init_ctx(&ctx);\n  do {\n    len = 0;\n    do {\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }\n    md5_process_block(buffer,0x1000,&ctx);\n  } while( true );\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint len;" type_identifier identifier ;) (declaration "md5_ctx ctx;" type_identifier identifier ;) (declaration "char buffer [4168];" primitive_type (array_declarator "buffer [4168]" identifier [ number_literal ]) ;) (expression_statement "md5_init_ctx(&ctx);" (call_expression "md5_init_ctx(&ctx)" identifier (argument_list "(&ctx)" ( (pointer_expression "&ctx" & identifier) ))) ;) (do_statement "do {\n    len = 0;\n    do {\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }\n    md5_process_block(buffer,0x1000,&ctx);\n  } while( true );" do (compound_statement "{\n    len = 0;\n    do {\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }\n    md5_process_block(buffer,0x1000,&ctx);\n  }" { (expression_statement "len = 0;" (assignment_expression "len = 0" identifier = number_literal) ;) (do_statement "do {\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    } while (sVar1 != 0);" do (compound_statement "{\n      sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);\n      len = len + sVar1;\n      if (0xfff < len) break;\n    }" { (expression_statement "sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream);" (assignment_expression "sVar1 = fread(buffer + len,1,0x1000 - len,(FILE *)stream)" identifier = (call_expression "fread(buffer + len,1,0x1000 - len,(FILE *)stream)" identifier (argument_list "(buffer + len,1,0x1000 - len,(FILE *)stream)" ( (binary_expression "buffer + len" identifier + identifier) , number_literal , (binary_expression "0x1000 - len" number_literal - identifier) , (cast_expression "(FILE *)stream" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) )))) ;) (expression_statement "len = len + sVar1;" (assignment_expression "len = len + sVar1" identifier = (binary_expression "len + sVar1" identifier + identifier)) ;) (if_statement "if (0xfff < len) break;" if (parenthesized_expression "(0xfff < len)" ( (binary_expression "0xfff < len" number_literal < identifier) )) (break_statement "break;" break ;)) }) while (parenthesized_expression "(sVar1 != 0)" ( (binary_expression "sVar1 != 0" identifier != number_literal) )) ;) (if_statement "if (sVar1 == 0) {\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }" if (parenthesized_expression "(sVar1 == 0)" ( (binary_expression "sVar1 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar2 = ferror((FILE *)stream);\n      if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }\n      return 1;\n    }" { (expression_statement "iVar2 = ferror((FILE *)stream);" (assignment_expression "iVar2 = ferror((FILE *)stream)" identifier = (call_expression "ferror((FILE *)stream)" identifier (argument_list "((FILE *)stream)" ( (cast_expression "(FILE *)stream" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) )))) ;) (if_statement "if (iVar2 == 0) {\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }\n        md5_finish_ctx(&ctx,resblock);\n        return 0;\n      }" { (if_statement "if (len != 0) {\n          md5_process_bytes(buffer,len,&ctx);\n        }" if (parenthesized_expression "(len != 0)" ( (binary_expression "len != 0" identifier != number_literal) )) (compound_statement "{\n          md5_process_bytes(buffer,len,&ctx);\n        }" { (expression_statement "md5_process_bytes(buffer,len,&ctx);" (call_expression "md5_process_bytes(buffer,len,&ctx)" identifier (argument_list "(buffer,len,&ctx)" ( identifier , identifier , (pointer_expression "&ctx" & identifier) ))) ;) })) (expression_statement "md5_finish_ctx(&ctx,resblock);" (call_expression "md5_finish_ctx(&ctx,resblock)" identifier (argument_list "(&ctx,resblock)" ( (pointer_expression "&ctx" & identifier) , identifier ))) ;) (return_statement "return 0;" return number_literal ;) })) (return_statement "return 1;" return number_literal ;) })) (expression_statement "md5_process_block(buffer,0x1000,&ctx);" (call_expression "md5_process_block(buffer,0x1000,&ctx)" identifier (argument_list "(buffer,0x1000,&ctx)" ( identifier , number_literal , (pointer_expression "&ctx" & identifier) ))) ;) }) while (parenthesized_expression "( true )" ( true )) ;) })))
(translation_unit "undefined4 FUN_00068fe0(FILE *param_1,undefined4 param_2)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}\n\n" (function_definition "undefined4 FUN_00068fe0(FILE *param_1,undefined4 param_2)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}" type_identifier (function_declarator "FUN_00068fe0(FILE *param_1,undefined4 param_2)" identifier (parameter_list "(FILE *param_1,undefined4 param_2)" ( (parameter_declaration "FILE *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined4 param_2" type_identifier identifier) ))) (compound_statement "{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "undefined1 local_1100 [156];" type_identifier (array_declarator "local_1100 [156]" identifier [ number_literal ]) ;) (declaration "undefined1 local_1064 [4176];" type_identifier (array_declarator "local_1064 [4176]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x68fe9;" (assignment_expression "uStack_14 = 0x68fe9" identifier = number_literal) ;) (expression_statement "FUN_00068420(local_1100);" (call_expression "FUN_00068420(local_1100)" identifier (argument_list "(local_1100)" ( identifier ))) ;) (do_statement "do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );" do (compound_statement "{\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  }" { (expression_statement "uVar3 = 0;" (assignment_expression "uVar3 = 0" identifier = number_literal) ;) (do_statement "do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);" do (compound_statement "{\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    }" { (expression_statement "sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);" (assignment_expression "sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" identifier = (call_expression "fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" identifier (argument_list "(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" ( (binary_expression "local_1064 + uVar3" identifier + identifier) , number_literal , (binary_expression "0x1000 - uVar3" number_literal - identifier) , identifier )))) ;) (expression_statement "uVar3 = uVar3 + sVar1;" (assignment_expression "uVar3 = uVar3 + sVar1" identifier = (binary_expression "uVar3 + sVar1" identifier + identifier)) ;) (if_statement "if (0xfff < uVar3) break;" if (parenthesized_expression "(0xfff < uVar3)" ( (binary_expression "0xfff < uVar3" number_literal < identifier) )) (break_statement "break;" break ;)) }) while (parenthesized_expression "(sVar1 != 0)" ( (binary_expression "sVar1 != 0" identifier != number_literal) )) ;) (if_statement "if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }" if (parenthesized_expression "(sVar1 == 0)" ( (binary_expression "sVar1 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }" { (expression_statement "iVar2 = ferror(param_1);" (assignment_expression "iVar2 = ferror(param_1)" identifier = (call_expression "ferror(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (if_statement "if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }" { (if_statement "if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }" if (parenthesized_expression "(uVar3 != 0)" ( (binary_expression "uVar3 != 0" identifier != number_literal) )) (compound_statement "{\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }" { (expression_statement "FUN_00068cb0(local_1064,uVar3,local_1100);" (call_expression "FUN_00068cb0(local_1064,uVar3,local_1100)" identifier (argument_list "(local_1064,uVar3,local_1100)" ( identifier , identifier , identifier ))) ;) })) (expression_statement "FUN_00068bf0(local_1100,param_2);" (call_expression "FUN_00068bf0(local_1100,param_2)" identifier (argument_list "(local_1100,param_2)" ( identifier , identifier ))) ;) (return_statement "return 0;" return number_literal ;) })) (return_statement "return 1;" return number_literal ;) })) (expression_statement "FUN_00068490(local_1064,0x1000,local_1100);" (call_expression "FUN_00068490(local_1064,0x1000,local_1100)" identifier (argument_list "(local_1064,0x1000,local_1100)" ( identifier , number_literal , identifier ))) ;) }) while (parenthesized_expression "( true )" ( true )) ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (binary_expression IDENT + IDENT) , LIT , (binary_expression LIT - IDENT) , IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (break_statement break ;)) }) while (parenthesized_expression ( (binary_expression IDENT != LIT) )) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (return_statement return LIT ;) })) (return_statement return LIT ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT , IDENT ))) ;) }) while (parenthesized_expression ( BOOL )) ;) })))
(function_definition "undefined4 FUN_00068fe0(FILE *param_1,undefined4 param_2)\n\n{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}" (type_identifier "undefined4") (function_declarator "FUN_00068fe0(FILE *param_1,undefined4 param_2)" (identifier "FUN_00068fe0") (parameter_list "(FILE *param_1,undefined4 param_2)" (( "(") (parameter_declaration "FILE *param_1" (type_identifier "FILE") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "undefined4 param_2" (type_identifier "undefined4") (identifier "param_2")) () ")"))) (compound_statement "{\n  size_t sVar1;\n  int iVar2;\n  uint uVar3;\n  undefined1 local_1100 [156];\n  undefined1 local_1064 [4176];\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x68fe9;\n  FUN_00068420(local_1100);\n  do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );\n}" ({ "{") (declaration "size_t sVar1;" (primitive_type "size_t") (identifier "sVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "uint uVar3;" (type_identifier "uint") (identifier "uVar3") (; ";")) (declaration "undefined1 local_1100 [156];" (type_identifier "undefined1") (array_declarator "local_1100 [156]" (identifier "local_1100") ([ "[") (number_literal "156") (] "]")) (; ";")) (declaration "undefined1 local_1064 [4176];" (type_identifier "undefined1") (array_declarator "local_1064 [4176]" (identifier "local_1064") ([ "[") (number_literal "4176") (] "]")) (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x68fe9;" (assignment_expression "uStack_14 = 0x68fe9" (identifier "uStack_14") (= "=") (number_literal "0x68fe9")) (; ";")) (expression_statement "FUN_00068420(local_1100);" (call_expression "FUN_00068420(local_1100)" (identifier "FUN_00068420") (argument_list "(local_1100)" (( "(") (identifier "local_1100") () ")"))) (; ";")) (do_statement "do {\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  } while( true );" (do "do") (compound_statement "{\n    uVar3 = 0;\n    do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);\n    if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }\n    FUN_00068490(local_1064,0x1000,local_1100);\n  }" ({ "{") (expression_statement "uVar3 = 0;" (assignment_expression "uVar3 = 0" (identifier "uVar3") (= "=") (number_literal "0")) (; ";")) (do_statement "do {\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    } while (sVar1 != 0);" (do "do") (compound_statement "{\n      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);\n      uVar3 = uVar3 + sVar1;\n      if (0xfff < uVar3) break;\n    }" ({ "{") (expression_statement "sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);" (assignment_expression "sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" (identifier "sVar1") (= "=") (call_expression "fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" (identifier "fread") (argument_list "(local_1064 + uVar3,1,0x1000 - uVar3,param_1)" (( "(") (binary_expression "local_1064 + uVar3" (identifier "local_1064") (+ "+") (identifier "uVar3")) (, ",") (number_literal "1") (, ",") (binary_expression "0x1000 - uVar3" (number_literal "0x1000") (- "-") (identifier "uVar3")) (, ",") (identifier "param_1") () ")")))) (; ";")) (expression_statement "uVar3 = uVar3 + sVar1;" (assignment_expression "uVar3 = uVar3 + sVar1" (identifier "uVar3") (= "=") (binary_expression "uVar3 + sVar1" (identifier "uVar3") (+ "+") (identifier "sVar1"))) (; ";")) (if_statement "if (0xfff < uVar3) break;" (if "if") (parenthesized_expression "(0xfff < uVar3)" (( "(") (binary_expression "0xfff < uVar3" (number_literal "0xfff") (< "<") (identifier "uVar3")) () ")")) (break_statement "break;" (break "break") (; ";"))) (} "}")) (while "while") (parenthesized_expression "(sVar1 != 0)" (( "(") (binary_expression "sVar1 != 0" (identifier "sVar1") (!= "!=") (number_literal "0")) () ")")) (; ";")) (if_statement "if (sVar1 == 0) {\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }" (if "if") (parenthesized_expression "(sVar1 == 0)" (( "(") (binary_expression "sVar1 == 0" (identifier "sVar1") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      iVar2 = ferror(param_1);\n      if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }\n      return 1;\n    }" ({ "{") (expression_statement "iVar2 = ferror(param_1);" (assignment_expression "iVar2 = ferror(param_1)" (identifier "iVar2") (= "=") (call_expression "ferror(param_1)" (identifier "ferror") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }\n        FUN_00068bf0(local_1100,param_2);\n        return 0;\n      }" ({ "{") (if_statement "if (uVar3 != 0) {\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }" (if "if") (parenthesized_expression "(uVar3 != 0)" (( "(") (binary_expression "uVar3 != 0" (identifier "uVar3") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n          FUN_00068cb0(local_1064,uVar3,local_1100);\n        }" ({ "{") (expression_statement "FUN_00068cb0(local_1064,uVar3,local_1100);" (call_expression "FUN_00068cb0(local_1064,uVar3,local_1100)" (identifier "FUN_00068cb0") (argument_list "(local_1064,uVar3,local_1100)" (( "(") (identifier "local_1064") (, ",") (identifier "uVar3") (, ",") (identifier "local_1100") () ")"))) (; ";")) (} "}"))) (expression_statement "FUN_00068bf0(local_1100,param_2);" (call_expression "FUN_00068bf0(local_1100,param_2)" (identifier "FUN_00068bf0") (argument_list "(local_1100,param_2)" (( "(") (identifier "local_1100") (, ",") (identifier "param_2") () ")"))) (; ";")) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (return_statement "return 1;" (return "return") (number_literal "1") (; ";")) (} "}"))) (expression_statement "FUN_00068490(local_1064,0x1000,local_1100);" (call_expression "FUN_00068490(local_1064,0x1000,local_1100)" (identifier "FUN_00068490") (argument_list "(local_1064,0x1000,local_1100)" (( "(") (identifier "local_1064") (, ",") (number_literal "0x1000") (, ",") (identifier "local_1100") () ")"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (; ";")) (} "}")))

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

int function_1(type_1 *stream,void *resblock)

{
  size_t var_5;
  int var_7;
  type_2 var_4;
  type_3 ctx;
  char var_3 [4168];
  
  var_1(&ctx);
  do {
    var_4 = 0;
    do {
      var_5 = var_2(var_3 + var_4,1,0x1000 - var_4,(type_1 *)stream);
      var_4 = var_4 + var_5;
      if (0xfff < var_4) break;
    } while (var_5 != 0);
    if (var_5 == 0) {
      var_7 = var_6((type_1 *)stream);
      if (var_7 == 0) {
        if (var_4 != 0) {
          var_8(var_3,var_4,&ctx);
        }
        var_9(&ctx,resblock);
        return 0;
      }
      return 1;
    }
    var_10(var_3,0x1000,&ctx);
  } while( true );
}


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

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

undefined4 MASKED(FILE *param_1,undefined4 param_2)

{
  size_t sVar1;
  int iVar2;
  uint uVar3;
  undefined1 local_1100 [156];
  undefined1 local_1064 [4176];
  undefined4 uStack_14;
  
  uStack_14 = 0x68fe9;
  FUN_00068420(local_1100);
  do {
    uVar3 = 0;
    do {
      sVar1 = fread(local_1064 + uVar3,1,0x1000 - uVar3,param_1);
      uVar3 = uVar3 + sVar1;
      if (0xfff < uVar3) break;
    } while (sVar1 != 0);
    if (sVar1 == 0) {
      iVar2 = ferror(param_1);
      if (iVar2 == 0) {
        if (uVar3 != 0) {
          FUN_00068cb0(local_1064,uVar3,local_1100);
        }
        FUN_00068bf0(local_1100,param_2);
        return 0;
      }
      return 1;
    }
    FUN_00068490(local_1064,0x1000,local_1100);
  } while( true );
}

