def check_zero(result, func, cargs):
    if result == 0:
        raise GEOSException('Error encountered in GEOS C function "%s".' % func.__name__)
    else:
        return result
Error checking on routines that should not return 0.
dataset/ETHPy150Open dcramer/django-compositepks/django/contrib/gis/geos/prototypes/errcheck.py/check_zero