#12857: Closing document while editing master pages may cause crash

git-svn-id: file:///svn/Scribus/trunk/Scribus@19678 11d20701-8431-0410-a711-e3c959e3b870