aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libcrystfel/src/dirax.c4
-rw-r--r--libcrystfel/src/felix.c2
-rw-r--r--libcrystfel/src/mosflm.c4
-rw-r--r--libcrystfel/src/xds.c5
4 files changed, 5 insertions, 10 deletions
diff --git a/libcrystfel/src/dirax.c b/libcrystfel/src/dirax.c
index 512a61e1..885afb97 100644
--- a/libcrystfel/src/dirax.c
+++ b/libcrystfel/src/dirax.c
@@ -660,9 +660,7 @@ const char *dirax_probe(UnitCell *cell)
}
fh = fdopen(pty, "r");
- if ( fgets(line, 1024, fh) == NULL ) {
- ERROR("Failed to probe for DirAx\n");
- } else {
+ if ( fgets(line, 1024, fh) != NULL ) {
if ( strncmp(line, "dirax", 5) == 0 ) {
ok = 1;
}
diff --git a/libcrystfel/src/felix.c b/libcrystfel/src/felix.c
index bbd82b0e..e02cfb44 100644
--- a/libcrystfel/src/felix.c
+++ b/libcrystfel/src/felix.c
@@ -737,7 +737,7 @@ const char *felix_probe(UnitCell *cell)
fh = fdopen(pty, "r");
if ( fgets(line, 1024, fh) == NULL ) {
- ERROR("Failed to probe for Felix\n");
+ ok = 0;
} else {
if ( strncmp(line, "Felix", 5) == 0 ) {
ok = 1;
diff --git a/libcrystfel/src/mosflm.c b/libcrystfel/src/mosflm.c
index 7ebf6e19..e59cf4e2 100644
--- a/libcrystfel/src/mosflm.c
+++ b/libcrystfel/src/mosflm.c
@@ -896,9 +896,7 @@ const char *mosflm_probe(UnitCell *cell)
for ( l=0; l<10; l++ ) {
char *pos;
- if ( fgets(line, 1024, fh) == NULL ) {
- ERROR("Failed to probe for Mosflm\n");
- } else {
+ if ( fgets(line, 1024, fh) != NULL ) {
pos = strstr(line, "Mosflm version ");
if ( pos != NULL ) {
char *vers = pos+15;
diff --git a/libcrystfel/src/xds.c b/libcrystfel/src/xds.c
index bfb977ea..b0dd0c47 100644
--- a/libcrystfel/src/xds.c
+++ b/libcrystfel/src/xds.c
@@ -679,9 +679,8 @@ const char *xds_probe(UnitCell *cell)
for ( l=0; l<10; l++ ) {
char *pos;
- if ( fgets(line, 1024, fh) == NULL ) {
- ERROR("Failed to probe for XDS\n");
- } else {
+ if ( fgets(line, 1024, fh) != NULL ) {
+ STATUS("got %s\n", line);
pos = strstr(line, "** XDS **");
if ( pos != NULL ) {
ok = 1;