summaryrefslogtreecommitdiff
path: root/src/lib/tng_io.c
diff options
context:
space:
mode:
authorMagnus Lundborg <lundborg.magnus@gmail.com>2013-11-14 10:01:20 (GMT)
committerMagnus Lundborg <lundborg.magnus@gmail.com>2013-11-14 10:01:20 (GMT)
commit4e77af15c632b2fcff2ce2ba5914c5e4b2539b05 (patch)
tree310dda54f27f92bbfaa43df1251fadfa76d0ea3d /src/lib/tng_io.c
parent746d750f60a96823acf36c56eb1d7ff0fcc31594 (diff)
Set the molecule count correctly in tng_implicit_num_particles_set()
Diffstat (limited to 'src/lib/tng_io.c')
-rw-r--r--src/lib/tng_io.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/tng_io.c b/src/lib/tng_io.c
index 0c72642..62883ca 100644
--- a/src/lib/tng_io.c
+++ b/src/lib/tng_io.c
@@ -9745,6 +9745,10 @@ tng_function_status DECLSPECDLLEXPORT tng_implicit_num_particles_set
return(stat);
}
stat = tng_residue_atom_add(tng_data, res, "", "", &atom);
+ if(stat != TNG_SUCCESS)
+ {
+ return(stat);
+ }
}
else
{
@@ -9761,8 +9765,8 @@ tng_function_status DECLSPECDLLEXPORT tng_implicit_num_particles_set
}
diff /= mol->n_atoms;
}
- stat = tng_molecule_cnt_set(tng_data, mol, diff);
}
+ stat = tng_molecule_cnt_set(tng_data, mol, diff);
}
return(stat);
contact: Jan Huwald // Impressum