Commits

Peter Brune committed cfb785c

Fix for accidentally duplicated refcount decrement in dm->x

The problem showed up in 2348bcf450f00165f06595d70d3a6539. Lisandro noticed it and Matt commented on it on Bitbucket.
However, dm->x is used in exactly two places in the code; neither of which is necessary. I consider it to be vestigial
and will remove it in next.

  • Participants
  • Parent commits 456fcb7

Comments (0)

Files changed (1)

src/dm/interface/dm.c

     if ((*dm)->globalin[i]) cnt++;
   }
   for (nlink=(*dm)->namedglobal; nlink; nlink=nlink->next) cnt++;
-  if ((*dm)->x) {
-    DM obj;
-    ierr = VecGetDM((*dm)->x, &obj);CHKERRQ(ierr);
-    if (obj == *dm) cnt++;
-  }
   for (nlink=(*dm)->namedlocal; nlink; nlink=nlink->next) cnt++;
   if ((*dm)->x) {
     DM obj;