Don't ignore the return value of fscanf.
Minor change to the calculation of the memory usage.