Fix crash after inserting lines via subs.insert