Add missing check for 0 length packet