def check_srs(result, func, cargs):
    if isinstance(result, six.integer_types):
        result = c_void_p(result)
    if not result:
        raise SRSException(func.__name__ % 'Invalid spatial reference pointer returned from "%s".')
    return result


# ### Other error-checking routines ###
dataset/ETHPy150Open django/django/django/contrib/gis/gdal/prototypes/errcheck.py/check_srs/swapped operands of `%`