From 6e5344464bdc5275eb04782284c0e19c26c217e4 Mon Sep 17 00:00:00 2001 From: Chris Young Date: Sat, 23 Dec 2017 14:14:20 +0000 Subject: [PATCH] Ensure we have a layer before deleting it. --- frontends/amiga/plotters.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontends/amiga/plotters.c b/frontends/amiga/plotters.c index 7c5df4678..728efb0c0 100644 --- a/frontends/amiga/plotters.c +++ b/frontends/amiga/plotters.c @@ -245,7 +245,7 @@ void ami_plot_ra_free(struct gui_globals *gg) } if(gg->rp) { - DeleteLayer(0,gg->rp->Layer); + if(gg->rp->Layer != NULL) DeleteLayer(0, gg->rp->Layer); free(gg->rp->TmpRas); free(gg->rp->AreaInfo); free(gg->rp);