[petsc-dev] Seg fault after changeset aa6a8e1
Barry Smith
bsmith at mcs.anl.gov
Tue Aug 18 12:51:26 CDT 2015
Yeah, this is my fault. When I reorganized the ASCII viewers to handle recursive use with sub viewers I had to remove the "short hand" ability to pass 0 (NULL) in as the PetscViewer to all the monitors that take a PetscViewer ASCII. But I did not add any error checking on the viewer, hence the crash. I also did not document this change.
So you need to now do either
> KSPMonitorSet(ksp, KSPMonitorTrueResidualNorm, PETSC_VIEWER_STDOUT_(PetscObjectComm((PetscObject)ksp))), NULL)
or create a Petsc ASCII viewer and call
> KSPMonitorSet(ksp, KSPMonitorTrueResidualNorm, viewer, (PetscErrorCode (*)(void**)) PetscViewerDestroy)
Thanks for reporting the problem,
Barry
I will push error checking and change into master and next.
> On Aug 18, 2015, at 7:07 AM, Garth N. Wells <gnw20 at cam.ac.uk> wrote:
>
> I get a seg fault on master since changeset aa6a8e1 (https://bitbucket.org/petsc/petsc/commits/aa6a8e194ee3df4b7fc8e67a3c63e52c695f2de4?at=master) when I call KSPMonitorSet(ksp, KSPMonitorTrueResidualNorm, NULL, NULL). Is there a problem with the changeset?
>
> Garth
More information about the petsc-dev
mailing list