From 1374dfa38ef7bdb7c18e92d058f51b3d79895cec Mon Sep 17 00:00:00 2001 From: Thomas White Date: Fri, 5 Feb 2010 10:14:09 +0100 Subject: Tidy up abort()s ... to avoid the special hell reserved for programmers who do this kind of thing. --- src/sfac.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/sfac.c') diff --git a/src/sfac.c b/src/sfac.c index 3d6e5f72..37b57ace 100644 --- a/src/sfac.c +++ b/src/sfac.c @@ -71,8 +71,9 @@ static double complex get_f1f2(const char *n, double en) r = sscanf(line, "%f %f %f", &E_f, &f1_f, &f2_f); if ( r != 3 ) { - ERROR("WTF?\n"); - abort(); + STATUS("I couldn't understand a line in the f1f2 " + "tables\n"); + continue; } /* Promote to double precision */ E = E_f; f1 = f1_f; f2 = f2_f; @@ -365,8 +366,8 @@ struct molecule *load_molecule() coords = line + 29; r = sscanf(coords, "%f %f %f %f %f", &xf, &yf, &zf, &occf, &Bf); if ( r != 5 ) { - ERROR("WTF?\n"); - abort(); + STATUS("I didn't understand a line in the PDB file.\n"); + continue; } /* Promote to double precision */ x = xf; y = yf; z = zf; occ = occf; B = Bf; -- cgit v1.2.3