Commit fc5db8a7 authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

fix off-by one bug when looking for bonds.

parent 56d0ab94
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -279,7 +279,7 @@ void ComputeCNAAtom::compute_peratom()
      for (n = 0; n < ncommon; n++) bonds[n] = 0;

      nbonds = 0;
      for (jj = 0; jj < ncommon; jj++) {
      for (jj = 0; jj < ncommon-1; jj++) {
        j = common[jj];
        xtmp = x[j][0];
        ytmp = x[j][1];