From 9178dce739cbfe1c14e105751778a0f7e61abad3 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Thu, 20 Sep 2018 14:55:12 +0200 Subject: Stop reading "simply" if file type is unknown --- libcrystfel/src/image.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'libcrystfel/src') diff --git a/libcrystfel/src/image.c b/libcrystfel/src/image.c index 31125725..d62e7ad5 100644 --- a/libcrystfel/src/image.c +++ b/libcrystfel/src/image.c @@ -896,8 +896,11 @@ int imagefile_read_simple(struct imagefile *f, struct image *image) { if ( f->type == IMAGEFILE_HDF5 ) { return hdf5_read(f->hdfile, image, NULL, 0); - } else { + } else if ( f->type == IMAGEFILE_CBF ) { return read_cbf_simple(f, image); + } else { + ERROR("Unknown file type %i\n", f->type); + return 1; } } -- cgit v1.2.3