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

char * __regparm3 read_body(FILE *fp)

{
  int iVar1;
  char *ptr;
  int iVar2;
  int iVar3;
  size_t local_24;
  
  ptr = (char *)safemalloc(0x80,1);
  *ptr = '\0';
  local_24 = 0x80;
  iVar3 = 0;
  while ((iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10))) {
    if (iVar2 == -1) {
      return ptr;
    }
    iVar1 = iVar3 + 1;
    if ((int)local_24 <= iVar1) {
      local_24 = local_24 + 0x80;
      ptr = (char *)saferealloc(ptr,local_24,1);
    }
    ptr[iVar3] = (char)iVar2;
    ptr[iVar1] = '\0';
    iVar3 = iVar1;
  }
  if ((iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))) {
    ungetc(iVar3,(FILE *)fp);
  }
  return ptr;
}



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

undefined1 * __regparm3 FUN_00053e50(FILE *param_1)

{
  int iVar1;
  undefined1 *puVar2;
  int iVar3;
  int iVar4;
  int local_24;
  
  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);
  *puVar2 = 0;
  local_24 = 0x80;
  iVar4 = 0;
  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {
    if (iVar3 == -1) {
      return puVar2;
    }
    iVar1 = iVar4 + 1;
    if (local_24 <= iVar1) {
      local_24 = local_24 + 0x80;
      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);
    }
    puVar2[iVar4] = (char)iVar3;
    puVar2[iVar1] = 0;
    iVar4 = iVar1;
  }
  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {
    ungetc(iVar4,param_1);
  }
  return puVar2;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00014980
ADD EBX,0x54f17
SUB ESP,0x24
MOV dword ptr [ESP + 0x14],EAX
PUSH 0x1
PUSH 0x80
CALL 0x0001a9c0
ADD ESP,0x10
XOR EDX,EDX
MOV EBP,EAX
MOV byte ptr [EAX],0x0
MOV dword ptr [ESP + 0x8],0x80
JMP 0x00053e9d
MOV EAX,ESI
MOV byte ptr [EBP + EDX*0x1],AL
MOV EDX,EDI
MOV byte ptr [EBP + EDI*0x1],0x0
MOV dword ptr [ESP + 0x4],EDX
SUB ESP,0xc
PUSH dword ptr [ESP + 0x18]
CALL 0x00014590
ADD ESP,0x10
MOV ESI,EAX
CMP EAX,0xd
JZ 0x00053ef8
CMP EAX,0xa
JZ 0x00053ef8
CMP EAX,-0x1
MOV EDX,dword ptr [ESP + 0x4]
JZ 0x00053f24
LEA EDI,[EDX + 0x1]
CMP EDI,dword ptr [ESP + 0x8]
JL 0x00053e90
SUB dword ptr [ESP + 0x8],-0x80
MOV EAX,dword ptr [ESP + 0x8]
SUB ESP,0x4
MOV dword ptr [ESP + 0x8],EDX
PUSH 0x1
PUSH EAX
PUSH EBP
CALL 0x0001adc0
ADD ESP,0x10
MOV EDX,dword ptr [ESP + 0x4]
MOV EBP,EAX
JMP 0x00053e90
CMP ESI,-0x1
JZ 0x00053f24
SUB ESP,0xc
MOV EDI,dword ptr [ESP + 0x18]
PUSH EDI
CALL 0x00014590
ADD ESP,0x10
CMP EAX,0xd
JZ 0x00053f24
CMP EAX,0xa
JZ 0x00053f24
SUB ESP,0x8
PUSH EDI
PUSH EAX
CALL 0x00014500
ADD ESP,0x10
ADD ESP,0x1c
MOV EAX,EBP
POP EBX
POP ESI
POP EDI
POP EBP
RET
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined1 * __regparm3 FUN_00053e50(FILE *param_1)\n\n{\n  int iVar1;\n  undefined1 *puVar2;\n  int iVar3;\n  int iVar4;\n  int local_24;\n  \n  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);\n  *puVar2 = 0;\n  local_24 = 0x80;\n  iVar4 = 0;\n  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }\n  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }\n  return puVar2;\n}\n\n" comment (ERROR "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)" (binary_expression "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)" identifier * (ERROR "__regparm3" identifier) (call_expression "FUN_00053e50(FILE *param_1)" identifier (argument_list "(FILE *param_1)" ( (binary_expression "FILE *param_1" identifier * identifier) ))))) (compound_statement "{\n  int iVar1;\n  undefined1 *puVar2;\n  int iVar3;\n  int iVar4;\n  int local_24;\n  \n  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);\n  *puVar2 = 0;\n  local_24 = 0x80;\n  iVar4 = 0;\n  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }\n  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }\n  return puVar2;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "undefined1 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int local_24;" primitive_type identifier ;) (expression_statement "puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);" (assignment_expression "puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1)" identifier = (cast_expression "(undefined1 *)FUN_0001a9c0(0x80,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001a9c0(0x80,1)" identifier (argument_list "(0x80,1)" ( number_literal , number_literal ))))) ;) (expression_statement "*puVar2 = 0;" (assignment_expression "*puVar2 = 0" (pointer_expression "*puVar2" * identifier) = number_literal) ;) (expression_statement "local_24 = 0x80;" (assignment_expression "local_24 = 0x80" identifier = number_literal) ;) (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" identifier = number_literal) ;) (while_statement "while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }" while (parenthesized_expression "((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10)))" ( (parenthesized_expression "(iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))" ( (comma_expression "iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10)" (assignment_expression "iVar3 = fgetc(param_1)" identifier = (call_expression "fgetc(param_1)" identifier (argument_list "(param_1)" ( identifier )))) , (binary_expression "iVar3 != 0xd && (iVar3 != 10)" (binary_expression "iVar3 != 0xd" identifier != number_literal) && (parenthesized_expression "(iVar3 != 10)" ( (binary_expression "iVar3 != 10" identifier != number_literal) )))) )) )) (compound_statement "{\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }" { (if_statement "if (iVar3 == -1) {\n      return puVar2;\n    }" if (parenthesized_expression "(iVar3 == -1)" ( (binary_expression "iVar3 == -1" identifier == number_literal) )) (compound_statement "{\n      return puVar2;\n    }" { (return_statement "return puVar2;" return identifier ;) })) (expression_statement "iVar1 = iVar4 + 1;" (assignment_expression "iVar1 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) (if_statement "if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }" if (parenthesized_expression "(local_24 <= iVar1)" ( (binary_expression "local_24 <= iVar1" identifier <= identifier) )) (compound_statement "{\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }" { (expression_statement "local_24 = local_24 + 0x80;" (assignment_expression "local_24 = local_24 + 0x80" identifier = (binary_expression "local_24 + 0x80" identifier + number_literal)) ;) (expression_statement "puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);" (assignment_expression "puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1)" identifier = (cast_expression "(undefined1 *)FUN_0001adc0(puVar2,local_24,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001adc0(puVar2,local_24,1)" identifier (argument_list "(puVar2,local_24,1)" ( identifier , identifier , number_literal ))))) ;) })) (expression_statement "puVar2[iVar4] = (char)iVar3;" (assignment_expression "puVar2[iVar4] = (char)iVar3" (subscript_expression "puVar2[iVar4]" identifier [ identifier ]) = (cast_expression "(char)iVar3" ( (type_descriptor "char" primitive_type) ) identifier)) ;) (expression_statement "puVar2[iVar1] = 0;" (assignment_expression "puVar2[iVar1] = 0" (subscript_expression "puVar2[iVar1]" identifier [ identifier ]) = number_literal) ;) (expression_statement "iVar4 = iVar1;" (assignment_expression "iVar4 = iVar1" identifier = identifier) ;) })) (if_statement "if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }" if (parenthesized_expression "((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10))))" ( (binary_expression "(iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))" (parenthesized_expression "(iVar3 != -1)" ( (binary_expression "iVar3 != -1" identifier != number_literal) )) && (parenthesized_expression "((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))" ( (parenthesized_expression "(iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10))" ( (comma_expression "iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)" (assignment_expression "iVar4 = fgetc(param_1)" identifier = (call_expression "fgetc(param_1)" identifier (argument_list "(param_1)" ( identifier )))) , (binary_expression "iVar4 != 0xd && (iVar4 != 10)" (binary_expression "iVar4 != 0xd" identifier != number_literal) && (parenthesized_expression "(iVar4 != 10)" ( (binary_expression "iVar4 != 10" identifier != number_literal) )))) )) ))) )) (compound_statement "{\n    ungetc(iVar4,param_1);\n  }" { (expression_statement "ungetc(iVar4,param_1);" (call_expression "ungetc(iVar4,param_1)" identifier (argument_list "(iVar4,param_1)" ( identifier , identifier ))) ;) })) (return_statement "return puVar2;" return identifier ;) }))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nchar * __regparm3 read_body(FILE *fp)\n\n{\n  int iVar1;\n  char *ptr;\n  int iVar2;\n  int iVar3;\n  size_t local_24;\n  \n  ptr = (char *)safemalloc(0x80,1);\n  *ptr = '\0';\n  local_24 = 0x80;\n  iVar3 = 0;\n  while ((iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10))) {\n    if (iVar2 == -1) {\n      return ptr;\n    }\n    iVar1 = iVar3 + 1;\n    if ((int)local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }\n    ptr[iVar3] = (char)iVar2;\n    ptr[iVar1] = '\0';\n    iVar3 = iVar1;\n  }\n  if ((iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))) {\n    ungetc(iVar3,(FILE *)fp);\n  }\n  return ptr;\n}\n\n" comment (function_definition "char * __regparm3 read_body(FILE *fp)\n\n{\n  int iVar1;\n  char *ptr;\n  int iVar2;\n  int iVar3;\n  size_t local_24;\n  \n  ptr = (char *)safemalloc(0x80,1);\n  *ptr = '\0';\n  local_24 = 0x80;\n  iVar3 = 0;\n  while ((iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10))) {\n    if (iVar2 == -1) {\n      return ptr;\n    }\n    iVar1 = iVar3 + 1;\n    if ((int)local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }\n    ptr[iVar3] = (char)iVar2;\n    ptr[iVar1] = '\0';\n    iVar3 = iVar1;\n  }\n  if ((iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))) {\n    ungetc(iVar3,(FILE *)fp);\n  }\n  return ptr;\n}" primitive_type (pointer_declarator "* __regparm3 read_body(FILE *fp)" * (ERROR "__regparm3" identifier) (function_declarator "read_body(FILE *fp)" identifier (parameter_list "(FILE *fp)" ( (parameter_declaration "FILE *fp" type_identifier (pointer_declarator "*fp" * identifier)) )))) (compound_statement "{\n  int iVar1;\n  char *ptr;\n  int iVar2;\n  int iVar3;\n  size_t local_24;\n  \n  ptr = (char *)safemalloc(0x80,1);\n  *ptr = '\0';\n  local_24 = 0x80;\n  iVar3 = 0;\n  while ((iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10))) {\n    if (iVar2 == -1) {\n      return ptr;\n    }\n    iVar1 = iVar3 + 1;\n    if ((int)local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }\n    ptr[iVar3] = (char)iVar2;\n    ptr[iVar1] = '\0';\n    iVar3 = iVar1;\n  }\n  if ((iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))) {\n    ungetc(iVar3,(FILE *)fp);\n  }\n  return ptr;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "char *ptr;" primitive_type (pointer_declarator "*ptr" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "size_t local_24;" primitive_type identifier ;) (expression_statement "ptr = (char *)safemalloc(0x80,1);" (assignment_expression "ptr = (char *)safemalloc(0x80,1)" identifier = (cast_expression "(char *)safemalloc(0x80,1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "safemalloc(0x80,1)" identifier (argument_list "(0x80,1)" ( number_literal , number_literal ))))) ;) (expression_statement "*ptr = '\0';" (assignment_expression "*ptr = '\0'" (pointer_expression "*ptr" * identifier) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "local_24 = 0x80;" (assignment_expression "local_24 = 0x80" identifier = number_literal) ;) (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (while_statement "while ((iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10))) {\n    if (iVar2 == -1) {\n      return ptr;\n    }\n    iVar1 = iVar3 + 1;\n    if ((int)local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }\n    ptr[iVar3] = (char)iVar2;\n    ptr[iVar1] = '\0';\n    iVar3 = iVar1;\n  }" while (parenthesized_expression "((iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10)))" ( (parenthesized_expression "(iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10))" ( (comma_expression "iVar2 = fgetc((FILE *)fp), iVar2 != 0xd && (iVar2 != 10)" (assignment_expression "iVar2 = fgetc((FILE *)fp)" identifier = (call_expression "fgetc((FILE *)fp)" identifier (argument_list "((FILE *)fp)" ( (cast_expression "(FILE *)fp" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) )))) , (binary_expression "iVar2 != 0xd && (iVar2 != 10)" (binary_expression "iVar2 != 0xd" identifier != number_literal) && (parenthesized_expression "(iVar2 != 10)" ( (binary_expression "iVar2 != 10" identifier != number_literal) )))) )) )) (compound_statement "{\n    if (iVar2 == -1) {\n      return ptr;\n    }\n    iVar1 = iVar3 + 1;\n    if ((int)local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }\n    ptr[iVar3] = (char)iVar2;\n    ptr[iVar1] = '\0';\n    iVar3 = iVar1;\n  }" { (if_statement "if (iVar2 == -1) {\n      return ptr;\n    }" if (parenthesized_expression "(iVar2 == -1)" ( (binary_expression "iVar2 == -1" identifier == number_literal) )) (compound_statement "{\n      return ptr;\n    }" { (return_statement "return ptr;" return identifier ;) })) (expression_statement "iVar1 = iVar3 + 1;" (assignment_expression "iVar1 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (if_statement "if ((int)local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }" if (parenthesized_expression "((int)local_24 <= iVar1)" ( (binary_expression "(int)local_24 <= iVar1" (cast_expression "(int)local_24" ( (type_descriptor "int" primitive_type) ) identifier) <= identifier) )) (compound_statement "{\n      local_24 = local_24 + 0x80;\n      ptr = (char *)saferealloc(ptr,local_24,1);\n    }" { (expression_statement "local_24 = local_24 + 0x80;" (assignment_expression "local_24 = local_24 + 0x80" identifier = (binary_expression "local_24 + 0x80" identifier + number_literal)) ;) (expression_statement "ptr = (char *)saferealloc(ptr,local_24,1);" (assignment_expression "ptr = (char *)saferealloc(ptr,local_24,1)" identifier = (cast_expression "(char *)saferealloc(ptr,local_24,1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "saferealloc(ptr,local_24,1)" identifier (argument_list "(ptr,local_24,1)" ( identifier , identifier , number_literal ))))) ;) })) (expression_statement "ptr[iVar3] = (char)iVar2;" (assignment_expression "ptr[iVar3] = (char)iVar2" (subscript_expression "ptr[iVar3]" identifier [ identifier ]) = (cast_expression "(char)iVar2" ( (type_descriptor "char" primitive_type) ) identifier)) ;) (expression_statement "ptr[iVar1] = '\0';" (assignment_expression "ptr[iVar1] = '\0'" (subscript_expression "ptr[iVar1]" identifier [ identifier ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "iVar3 = iVar1;" (assignment_expression "iVar3 = iVar1" identifier = identifier) ;) })) (if_statement "if ((iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))) {\n    ungetc(iVar3,(FILE *)fp);\n  }" if (parenthesized_expression "((iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10))))" ( (binary_expression "(iVar2 != -1) && ((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))" (parenthesized_expression "(iVar2 != -1)" ( (binary_expression "iVar2 != -1" identifier != number_literal) )) && (parenthesized_expression "((iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)))" ( (parenthesized_expression "(iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10))" ( (comma_expression "iVar3 = fgetc((FILE *)fp), iVar3 != 0xd && (iVar3 != 10)" (assignment_expression "iVar3 = fgetc((FILE *)fp)" identifier = (call_expression "fgetc((FILE *)fp)" identifier (argument_list "((FILE *)fp)" ( (cast_expression "(FILE *)fp" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) )))) , (binary_expression "iVar3 != 0xd && (iVar3 != 10)" (binary_expression "iVar3 != 0xd" identifier != number_literal) && (parenthesized_expression "(iVar3 != 10)" ( (binary_expression "iVar3 != 10" identifier != number_literal) )))) )) ))) )) (compound_statement "{\n    ungetc(iVar3,(FILE *)fp);\n  }" { (expression_statement "ungetc(iVar3,(FILE *)fp);" (call_expression "ungetc(iVar3,(FILE *)fp)" identifier (argument_list "(iVar3,(FILE *)fp)" ( identifier , (cast_expression "(FILE *)fp" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) ))) ;) })) (return_statement "return ptr;" return identifier ;) })))
(translation_unit "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)\n\n{\n  int iVar1;\n  undefined1 *puVar2;\n  int iVar3;\n  int iVar4;\n  int local_24;\n  \n  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);\n  *puVar2 = 0;\n  local_24 = 0x80;\n  iVar4 = 0;\n  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }\n  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }\n  return puVar2;\n}\n\n" (ERROR "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)" (binary_expression "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)" identifier * (ERROR "__regparm3" identifier) (call_expression "FUN_00053e50(FILE *param_1)" identifier (argument_list "(FILE *param_1)" ( (binary_expression "FILE *param_1" identifier * identifier) ))))) (compound_statement "{\n  int iVar1;\n  undefined1 *puVar2;\n  int iVar3;\n  int iVar4;\n  int local_24;\n  \n  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);\n  *puVar2 = 0;\n  local_24 = 0x80;\n  iVar4 = 0;\n  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }\n  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }\n  return puVar2;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "undefined1 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int local_24;" primitive_type identifier ;) (expression_statement "puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);" (assignment_expression "puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1)" identifier = (cast_expression "(undefined1 *)FUN_0001a9c0(0x80,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001a9c0(0x80,1)" identifier (argument_list "(0x80,1)" ( number_literal , number_literal ))))) ;) (expression_statement "*puVar2 = 0;" (assignment_expression "*puVar2 = 0" (pointer_expression "*puVar2" * identifier) = number_literal) ;) (expression_statement "local_24 = 0x80;" (assignment_expression "local_24 = 0x80" identifier = number_literal) ;) (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" identifier = number_literal) ;) (while_statement "while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }" while (parenthesized_expression "((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10)))" ( (parenthesized_expression "(iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))" ( (comma_expression "iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10)" (assignment_expression "iVar3 = fgetc(param_1)" identifier = (call_expression "fgetc(param_1)" identifier (argument_list "(param_1)" ( identifier )))) , (binary_expression "iVar3 != 0xd && (iVar3 != 10)" (binary_expression "iVar3 != 0xd" identifier != number_literal) && (parenthesized_expression "(iVar3 != 10)" ( (binary_expression "iVar3 != 10" identifier != number_literal) )))) )) )) (compound_statement "{\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }" { (if_statement "if (iVar3 == -1) {\n      return puVar2;\n    }" if (parenthesized_expression "(iVar3 == -1)" ( (binary_expression "iVar3 == -1" identifier == number_literal) )) (compound_statement "{\n      return puVar2;\n    }" { (return_statement "return puVar2;" return identifier ;) })) (expression_statement "iVar1 = iVar4 + 1;" (assignment_expression "iVar1 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) (if_statement "if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }" if (parenthesized_expression "(local_24 <= iVar1)" ( (binary_expression "local_24 <= iVar1" identifier <= identifier) )) (compound_statement "{\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }" { (expression_statement "local_24 = local_24 + 0x80;" (assignment_expression "local_24 = local_24 + 0x80" identifier = (binary_expression "local_24 + 0x80" identifier + number_literal)) ;) (expression_statement "puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);" (assignment_expression "puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1)" identifier = (cast_expression "(undefined1 *)FUN_0001adc0(puVar2,local_24,1)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001adc0(puVar2,local_24,1)" identifier (argument_list "(puVar2,local_24,1)" ( identifier , identifier , number_literal ))))) ;) })) (expression_statement "puVar2[iVar4] = (char)iVar3;" (assignment_expression "puVar2[iVar4] = (char)iVar3" (subscript_expression "puVar2[iVar4]" identifier [ identifier ]) = (cast_expression "(char)iVar3" ( (type_descriptor "char" primitive_type) ) identifier)) ;) (expression_statement "puVar2[iVar1] = 0;" (assignment_expression "puVar2[iVar1] = 0" (subscript_expression "puVar2[iVar1]" identifier [ identifier ]) = number_literal) ;) (expression_statement "iVar4 = iVar1;" (assignment_expression "iVar4 = iVar1" identifier = identifier) ;) })) (if_statement "if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }" if (parenthesized_expression "((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10))))" ( (binary_expression "(iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))" (parenthesized_expression "(iVar3 != -1)" ( (binary_expression "iVar3 != -1" identifier != number_literal) )) && (parenthesized_expression "((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))" ( (parenthesized_expression "(iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10))" ( (comma_expression "iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)" (assignment_expression "iVar4 = fgetc(param_1)" identifier = (call_expression "fgetc(param_1)" identifier (argument_list "(param_1)" ( identifier )))) , (binary_expression "iVar4 != 0xd && (iVar4 != 10)" (binary_expression "iVar4 != 0xd" identifier != number_literal) && (parenthesized_expression "(iVar4 != 10)" ( (binary_expression "iVar4 != 10" identifier != number_literal) )))) )) ))) )) (compound_statement "{\n    ungetc(iVar4,param_1);\n  }" { (expression_statement "ungetc(iVar4,param_1);" (call_expression "ungetc(iVar4,param_1)" identifier (argument_list "(iVar4,param_1)" ( identifier , identifier ))) ;) })) (return_statement "return puVar2;" return identifier ;) }))
(translation_unit (ERROR (binary_expression IDENT * (ERROR IDENT) (call_expression IDENT (argument_list ( (binary_expression IDENT * IDENT) ))))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( LIT , LIT ))))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (while_statement while (parenthesized_expression ( (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) , (binary_expression (binary_expression IDENT != LIT) && (parenthesized_expression ( (binary_expression IDENT != LIT) )))) )) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (return_statement return IDENT ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , IDENT , LIT ))))) ;) })) (expression_statement (assignment_expression (subscript_expression IDENT [ IDENT ]) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ IDENT ]) = LIT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) && (parenthesized_expression ( (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) , (binary_expression (binary_expression IDENT != LIT) && (parenthesized_expression ( (binary_expression IDENT != LIT) )))) )) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) })) (return_statement return IDENT ;) }))
(ERROR "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)" (binary_expression "undefined1 * __regparm3 FUN_00053e50(FILE *param_1)" (identifier "undefined1") (* "*") (ERROR "__regparm3" (identifier "__regparm3")) (call_expression "FUN_00053e50(FILE *param_1)" (identifier "FUN_00053e50") (argument_list "(FILE *param_1)" (( "(") (binary_expression "FILE *param_1" (identifier "FILE") (* "*") (identifier "param_1")) () ")"))))) (compound_statement "{\n  int iVar1;\n  undefined1 *puVar2;\n  int iVar3;\n  int iVar4;\n  int local_24;\n  \n  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);\n  *puVar2 = 0;\n  local_24 = 0x80;\n  iVar4 = 0;\n  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }\n  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }\n  return puVar2;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "undefined1 *puVar2;" (type_identifier "undefined1") (pointer_declarator "*puVar2" (* "*") (identifier "puVar2")) (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "int local_24;" (primitive_type "int") (identifier "local_24") (; ";")) (expression_statement "puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);" (assignment_expression "puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1)" (identifier "puVar2") (= "=") (cast_expression "(undefined1 *)FUN_0001a9c0(0x80,1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0001a9c0(0x80,1)" (identifier "FUN_0001a9c0") (argument_list "(0x80,1)" (( "(") (number_literal "0x80") (, ",") (number_literal "1") () ")"))))) (; ";")) (expression_statement "*puVar2 = 0;" (assignment_expression "*puVar2 = 0" (pointer_expression "*puVar2" (* "*") (identifier "puVar2")) (= "=") (number_literal "0")) (; ";")) (expression_statement "local_24 = 0x80;" (assignment_expression "local_24 = 0x80" (identifier "local_24") (= "=") (number_literal "0x80")) (; ";")) (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" (identifier "iVar4") (= "=") (number_literal "0")) (; ";")) (while_statement "while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }" (while "while") (parenthesized_expression "((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10)))" (( "(") (parenthesized_expression "(iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))" (( "(") (comma_expression "iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10)" (assignment_expression "iVar3 = fgetc(param_1)" (identifier "iVar3") (= "=") (call_expression "fgetc(param_1)" (identifier "fgetc") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (, ",") (binary_expression "iVar3 != 0xd && (iVar3 != 10)" (binary_expression "iVar3 != 0xd" (identifier "iVar3") (!= "!=") (number_literal "0xd")) (&& "&&") (parenthesized_expression "(iVar3 != 10)" (( "(") (binary_expression "iVar3 != 10" (identifier "iVar3") (!= "!=") (number_literal "10")) () ")")))) () ")")) () ")")) (compound_statement "{\n    if (iVar3 == -1) {\n      return puVar2;\n    }\n    iVar1 = iVar4 + 1;\n    if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }\n    puVar2[iVar4] = (char)iVar3;\n    puVar2[iVar1] = 0;\n    iVar4 = iVar1;\n  }" ({ "{") (if_statement "if (iVar3 == -1) {\n      return puVar2;\n    }" (if "if") (parenthesized_expression "(iVar3 == -1)" (( "(") (binary_expression "iVar3 == -1" (identifier "iVar3") (== "==") (number_literal "-1")) () ")")) (compound_statement "{\n      return puVar2;\n    }" ({ "{") (return_statement "return puVar2;" (return "return") (identifier "puVar2") (; ";")) (} "}"))) (expression_statement "iVar1 = iVar4 + 1;" (assignment_expression "iVar1 = iVar4 + 1" (identifier "iVar1") (= "=") (binary_expression "iVar4 + 1" (identifier "iVar4") (+ "+") (number_literal "1"))) (; ";")) (if_statement "if (local_24 <= iVar1) {\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }" (if "if") (parenthesized_expression "(local_24 <= iVar1)" (( "(") (binary_expression "local_24 <= iVar1" (identifier "local_24") (<= "<=") (identifier "iVar1")) () ")")) (compound_statement "{\n      local_24 = local_24 + 0x80;\n      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);\n    }" ({ "{") (expression_statement "local_24 = local_24 + 0x80;" (assignment_expression "local_24 = local_24 + 0x80" (identifier "local_24") (= "=") (binary_expression "local_24 + 0x80" (identifier "local_24") (+ "+") (number_literal "0x80"))) (; ";")) (expression_statement "puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);" (assignment_expression "puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1)" (identifier "puVar2") (= "=") (cast_expression "(undefined1 *)FUN_0001adc0(puVar2,local_24,1)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0001adc0(puVar2,local_24,1)" (identifier "FUN_0001adc0") (argument_list "(puVar2,local_24,1)" (( "(") (identifier "puVar2") (, ",") (identifier "local_24") (, ",") (number_literal "1") () ")"))))) (; ";")) (} "}"))) (expression_statement "puVar2[iVar4] = (char)iVar3;" (assignment_expression "puVar2[iVar4] = (char)iVar3" (subscript_expression "puVar2[iVar4]" (identifier "puVar2") ([ "[") (identifier "iVar4") (] "]")) (= "=") (cast_expression "(char)iVar3" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (identifier "iVar3"))) (; ";")) (expression_statement "puVar2[iVar1] = 0;" (assignment_expression "puVar2[iVar1] = 0" (subscript_expression "puVar2[iVar1]" (identifier "puVar2") ([ "[") (identifier "iVar1") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "iVar4 = iVar1;" (assignment_expression "iVar4 = iVar1" (identifier "iVar4") (= "=") (identifier "iVar1")) (; ";")) (} "}"))) (if_statement "if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {\n    ungetc(iVar4,param_1);\n  }" (if "if") (parenthesized_expression "((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10))))" (( "(") (binary_expression "(iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))" (parenthesized_expression "(iVar3 != -1)" (( "(") (binary_expression "iVar3 != -1" (identifier "iVar3") (!= "!=") (number_literal "-1")) () ")")) (&& "&&") (parenthesized_expression "((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))" (( "(") (parenthesized_expression "(iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10))" (( "(") (comma_expression "iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)" (assignment_expression "iVar4 = fgetc(param_1)" (identifier "iVar4") (= "=") (call_expression "fgetc(param_1)" (identifier "fgetc") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (, ",") (binary_expression "iVar4 != 0xd && (iVar4 != 10)" (binary_expression "iVar4 != 0xd" (identifier "iVar4") (!= "!=") (number_literal "0xd")) (&& "&&") (parenthesized_expression "(iVar4 != 10)" (( "(") (binary_expression "iVar4 != 10" (identifier "iVar4") (!= "!=") (number_literal "10")) () ")")))) () ")")) () ")"))) () ")")) (compound_statement "{\n    ungetc(iVar4,param_1);\n  }" ({ "{") (expression_statement "ungetc(iVar4,param_1);" (call_expression "ungetc(iVar4,param_1)" (identifier "ungetc") (argument_list "(iVar4,param_1)" (( "(") (identifier "iVar4") (, ",") (identifier "param_1") () ")"))) (; ";")) (} "}"))) (return_statement "return puVar2;" (return "return") (identifier "puVar2") (; ";")) (} "}"))

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

char * __regparm3 function_1(type_1 *fp)

{
  int var_5;
  char *ptr;
  int var_3;
  int var_4;
  size_t var_6;
  
  ptr = (char *)var_1(0x80,1);
  *ptr = '\0';
  var_6 = 0x80;
  var_4 = 0;
  while ((var_3 = var_2((type_1 *)fp), var_3 != 0xd && (var_3 != 10))) {
    if (var_3 == -1) {
      return ptr;
    }
    var_5 = var_4 + 1;
    if ((int)var_6 <= var_5) {
      var_6 = var_6 + 0x80;
      ptr = (char *)var_7(ptr,var_6,1);
    }
    ptr[var_4] = (char)var_3;
    ptr[var_5] = '\0';
    var_4 = var_5;
  }
  if ((var_3 != -1) && ((var_4 = var_2((type_1 *)fp), var_4 != 0xd && (var_4 != 10)))) {
    var_8(var_4,(type_1 *)fp);
  }
  return ptr;
}


(translation_unit (ERROR (binary_expression left: (identifier) (ERROR (identifier)) right: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (identifier)))))) (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (number_literal) (number_literal)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (while_statement condition: (parenthesized_expression (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier)))) right: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) body: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal)))))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier)))) right: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))))) (return_statement (identifier))))

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

undefined1 * __regparm3 MASKED(FILE *param_1)

{
  int iVar1;
  undefined1 *puVar2;
  int iVar3;
  int iVar4;
  int local_24;
  
  puVar2 = (undefined1 *)FUN_0001a9c0(0x80,1);
  *puVar2 = 0;
  local_24 = 0x80;
  iVar4 = 0;
  while ((iVar3 = fgetc(param_1), iVar3 != 0xd && (iVar3 != 10))) {
    if (iVar3 == -1) {
      return puVar2;
    }
    iVar1 = iVar4 + 1;
    if (local_24 <= iVar1) {
      local_24 = local_24 + 0x80;
      puVar2 = (undefined1 *)FUN_0001adc0(puVar2,local_24,1);
    }
    puVar2[iVar4] = (char)iVar3;
    puVar2[iVar1] = 0;
    iVar4 = iVar1;
  }
  if ((iVar3 != -1) && ((iVar4 = fgetc(param_1), iVar4 != 0xd && (iVar4 != 10)))) {
    ungetc(iVar4,param_1);
  }
  return puVar2;
}

