aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/PJ_hgridshift.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/PJ_hgridshift.c b/src/PJ_hgridshift.c
index 41c2b629..674b4da8 100644
--- a/src/PJ_hgridshift.c
+++ b/src/PJ_hgridshift.c
@@ -81,6 +81,8 @@ PJ *PROJECTION(hgridshift) {
/* Was gridlist compiled properly? */
if ( pj_ctx_get_errno(P->ctx) ) {
proj_log_error(P, "hgridshift: could not find required grid(s).");
+ pj_dalloc(P->gridlist);
+ P->gridlist = NULL;
return freeup_msg(P, -38);
}