Fix clipExtent bug.

If a polygon does not intersect with the extent, but has one or more
rings inside the extent, then the extent should be checked to see
whether it is inside the polygon: if so, an additional exterior ring is
generated.

Previously, this check was only made if there were no visible rings at
all.

Fixes an issue noticed in #1453.