diff options
author | Thomas White <taw@physics.org> | 2020-07-01 11:56:21 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2020-07-29 18:53:44 +0200 |
commit | b1cb4ee55dc493808b8408ada63c5c59a301399e (patch) | |
tree | f32f025934d72b08e2bd996831aaf1f9a7660939 | |
parent | 565268d27911fcdda767f483df461eead1b917d9 (diff) |
Don't try to draw peaks without an image structure
-rw-r--r-- | src/crystfelimageview.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/crystfelimageview.c b/src/crystfelimageview.c index 36989ce4..cde4459c 100644 --- a/src/crystfelimageview.c +++ b/src/crystfelimageview.c @@ -445,7 +445,9 @@ static gint draw_sig(GtkWidget *window, cairo_t *cr, CrystFELImageView *iv) } for ( i=0; i<iv->num_peaklists; i++ ){ - if ( iv->peaklists[i] != NULL ) { + if ( (iv->peaklists[i] != NULL) + && (iv->image != NULL) ) + { draw_peaks(cr, iv , iv->peaklists[i]); } } |