Don't create zero-length lines
Fix stupid typo, compile failure
Fix crash after creating zero-length cursor line