Skip to content

Commit

Permalink
Sketcher: fix access to isPerformingTransaction on null pointer
Browse files Browse the repository at this point in the history
===============================================================

Fixes this crash:
https://forum.freecadweb.org/viewtopic.php?f=3&t=48414#p414255
  • Loading branch information
abdullahtahiriyo committed Jul 7, 2020
1 parent c3da895 commit 39b81e4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Mod/Sketcher/App/SketchObject.cpp
Expand Up @@ -7040,7 +7040,9 @@ void SketchObject::onChanged(const App::Property* prop)

if (prop == &Geometry || prop == &Constraints) {

if(getDocument()->isPerformingTransaction()) { // undo/redo
auto doc = getDocument();

if(doc && doc->isPerformingTransaction()) { // undo/redo
setStatus(App::PendingTransactionUpdate, true);
}
else {
Expand Down

0 comments on commit 39b81e4

Please sign in to comment.