# HG changeset patch # User Santeri Piippo # Date 1398559870 -10800 # Node ID 54c321f4d102c3883a1f0dd37960d5005b1a673e # Parent cdce1cbaac7ef407143776de2e17ea8ad16e40f4 - when setting the current document, the GL compiler must be told that a merge is necessary *before* setting the renderer's document as setDocument will call zoomToFit which renders the scene. this rendering must trigger a merge or ldforge crashes if a new document is created when a document is already open. diff -r cdce1cbaac7e -r 54c321f4d102 src/ldDocument.cc --- a/src/ldDocument.cc Thu Apr 24 02:08:53 2014 +0300 +++ b/src/ldDocument.cc Sun Apr 27 03:51:10 2014 +0300 @@ -1399,8 +1399,8 @@ g_win->updateDocumentListItem (f); g_win->buildObjList(); g_win->updateTitle(); + g_win->R()->compiler()->needMerge(); g_win->R()->setDocument (f); - g_win->R()->compiler()->needMerge(); print ("Changed file to %1", f->getDisplayName()); } }