fixed test for malformed packets.