From 19e227bd6e27c442081d5a35ddeeb557e3ea56b6 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Wed, 27 Jun 2018 17:19:44 +0200 Subject: Felix: Complain if cell not provided Prevents a confusing error message that Felix doesn't work, when in fact the problem is that no cell has been given (and Felix needs one). --- libcrystfel/src/felix.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libcrystfel/src/felix.c b/libcrystfel/src/felix.c index e686c2e6..f87892c7 100644 --- a/libcrystfel/src/felix.c +++ b/libcrystfel/src/felix.c @@ -613,14 +613,14 @@ void *felix_prepare(IndexingMethod *indm, UnitCell *cell, { struct felix_private *gp; - if ( felix_probe(cell) == NULL ) { - ERROR("Felix does not appear to run properly.\n"); - ERROR("Please check your Felix installation.\n"); + if ( !cell_has_parameters(cell) ) { + ERROR("Felix needs a unit cell.\n"); return NULL; } - if ( !cell_has_parameters(cell) ) { - ERROR("Felix needs a unit cell.\n"); + if ( felix_probe(cell) == NULL ) { + ERROR("Felix does not appear to run properly.\n"); + ERROR("Please check your Felix installation.\n"); return NULL; } -- cgit v1.2.3