fix an issue with zero length events