gh2941: fix LinearEntity intersection problems

fixes #2941