Fix error handling in glcm.

The continue statement was in the wrong place.