]> granicus.if.org Git - postgis/commitdiff
Do not allow loading offline rasters when explicitly disabled
authorSandro Santilli <strk@keybit.net>
Thu, 10 Apr 2014 14:35:17 +0000 (14:35 +0000)
committerSandro Santilli <strk@keybit.net>
Thu, 10 Apr 2014 14:35:17 +0000 (14:35 +0000)
Previous commit only disabled _saving_ rasters with offline flag,
this one prevents actually loading the offline data.
You can still dump databases with offline raster specs.

git-svn-id: http://svn.osgeo.org/postgis/trunk@12455 b70326c6-7e19-0410-871a-916f4a2858ee

raster/rt_core/rt_band.c

index cb7c72543d541b4aedf4ea922c40190a4c70b74d..ce088d22b7986388c55b97e92bdcc0d9e739f343 100644 (file)
@@ -352,6 +352,13 @@ rt_band_load_offline_data(rt_band band) {
                return ES_ERROR;
        }
 
+#ifdef POSTGIS_RASTER_DISABLE_OFFLINE
+       rterror("rt_raster_load_offline_data: "
+               "offline raster support disabled at compile-time");
+       return ES_ERROR;
+#endif
+
+
        rt_util_gdal_register_all();
        /*
        hdsSrc = GDALOpenShared(band->data.offline.path, GA_ReadOnly);