Ensure draw line only inside polygon works correctly with multipolygon rings (fix #9624)