More refactoring. And added a check to RecordMagWeb to make sure we have
a long enough packet.