Commits

Matt Knepley  committed 4931084 Merge

Merge branch 'knepley/fix-hash-scaling' into knepley/pylith

* knepley/fix-hash-scaling:
DMPlex: Fixed mismatched Malloc2 in reordering

  • Participants
  • Parent commits afdbcbd, 40c0e26
  • Branches knepley/pylith

Comments (0)

Files changed (1)

File src/dm/impls/plex/plexreorder.c

   PetscFunctionBegin;
   ierr = DMPlexGetDepth(dm, &depth);CHKERRQ(ierr);
   ierr = DMPlexGetChart(dm, &pStart, &pEnd);CHKERRQ(ierr);
-  ierr = PetscMalloc2(pEnd-pStart,PetscInt,&perm,pEnd-pStart,PetscInt,&iperm);CHKERRQ(ierr);
+  ierr = PetscMalloc(pEnd-pStart * sizeof(PetscInt), &perm);CHKERRQ(ierr);
+  ierr = PetscMalloc(pEnd-pStart * sizeof(PetscInt) ,&iperm);CHKERRQ(ierr);
   for (p = pStart; p < pEnd; ++p) iperm[p] = -1;
   for (d = depth; d > 0; --d) {
     ierr = DMPlexGetDepthStratum(dm, d,   &pStart, &pEnd);CHKERRQ(ierr);