From e33d03ec2c1929e722713e0c3576b7775d4e2741 Mon Sep 17 00:00:00 2001 From: sjplimp Date: Wed, 21 Aug 2013 14:59:02 +0000 Subject: [PATCH] git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@10622 f3b2605a-c512-4ea7-a41b-209d697bcdaa --- src/RIGID/fix_rigid_small.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/RIGID/fix_rigid_small.cpp b/src/RIGID/fix_rigid_small.cpp index c46f2cd89c..c0662e5e82 100644 --- a/src/RIGID/fix_rigid_small.cpp +++ b/src/RIGID/fix_rigid_small.cpp @@ -2127,11 +2127,14 @@ void FixRigidSmall::readfile(int which, double **array, int *inbody) values[0] = strtok(buf," \t\n\r\f"); for (j = 1; j < nwords; j++) values[j] = strtok(NULL," \t\n\r\f"); - + id = atoi(values[0]); if (id <= 0 || id > maxmol) error->all(FLERR,"Invalid rigid body ID in fix rigid/small file"); - if (hash->find(id) == hash->end()) continue; + if (hash->find(id) == hash->end()) { + buf = next + 1; + continue; + } id = (*hash)[id]; inbody[id] = 1;