aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src/felix.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2018-06-27 17:19:44 +0200
committerThomas White <taw@physics.org>2018-06-28 11:27:49 +0200
commit19e227bd6e27c442081d5a35ddeeb557e3ea56b6 (patch)
tree173bccecf598d82cebd90690ed090c95c5da39aa /libcrystfel/src/felix.c
parent33dfce497f2dcdcf071f6f83d88756b0f6bd99df (diff)
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).
Diffstat (limited to 'libcrystfel/src/felix.c')
-rw-r--r--libcrystfel/src/felix.c10
1 files 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;
}