Fixed bugs with record keeping for the proc file.