summaryrefslogtreecommitdiff
blob: 7a614edff72e02e0e357cfb0e432e0d83432eec7 (plain)
1
2
3
4
5
6
7
8
9
10
11
--- a/tview.cpp
+++ b/tview.cpp
@@ -208,7 +208,7 @@
 		pictureFileName, wxT("SVG vector picture files (*.svg)|*.svg"),
 		wxSAVE|wxOVERWRITE_PROMPT);
 
-    if (dialog.ShowModal() == wxID_OK)
+    if ((dialog.ShowModal() == wxID_OK) && (p.GetNumTrees() != 0))
     {
 		wxSVGFileDC pictureDC (dialog.GetPath(), 600, 650) ;
 		OnDraw (&pictureDC);