read into
record1
from
f1
; if
f1
empty, signify by setting flag to 1
if(fread(&record1,length,1,f1_ptr) == 0)
{
flag = 1;