From 7063a85579f40585f2601ba6e6887b0982e7ce43 Mon Sep 17 00:00:00 2001 From: Sergey Fedoseev Date: Tue, 21 Mar 2017 20:45:12 +0500 Subject: [PATCH] Fixed #27960 -- Set errcheck=False for GDALAllRegister to prevent crash. GDALAllRegister returns void so errcheck is not needed. --- django/contrib/gis/gdal/prototypes/raster.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django/contrib/gis/gdal/prototypes/raster.py b/django/contrib/gis/gdal/prototypes/raster.py index b4519a853d..af710dfb6d 100644 --- a/django/contrib/gis/gdal/prototypes/raster.py +++ b/django/contrib/gis/gdal/prototypes/raster.py @@ -21,7 +21,7 @@ const_string_output = partial(const_string_output, cpl=True) double_output = partial(double_output, cpl=True) # Raster Driver Routines -register_all = void_output(std_call('GDALAllRegister'), []) +register_all = void_output(std_call('GDALAllRegister'), [], errcheck=False) get_driver = voidptr_output(std_call('GDALGetDriver'), [c_int]) get_driver_by_name = voidptr_output(std_call('GDALGetDriverByName'), [c_char_p], errcheck=False) get_driver_count = int_output(std_call('GDALGetDriverCount'), [])