소스 검색

wxGUI: fix d.out.file command parsing with --overwrite (#1284)

Anna Petrasova 4 년 전
부모
커밋
4165830291
1개의 변경된 파일5개의 추가작업 그리고 1개의 파일을 삭제
  1. 5 1
      gui/wxpython/mapdisp/frame.py

+ 5 - 1
gui/wxpython/mapdisp/frame.py

@@ -669,7 +669,11 @@ class MapFrame(SingleMapFrame):
             return
         width, height = self.MapWindow.GetClientSize()
         for param in command[1:]:
-            p, val = param.split('=')
+            try:
+                p, val = param.split('=')
+            except ValueError:
+                # --overwrite
+                continue
             if p == 'format':  # must be there
                 if self.IsPaneShown('3d'):
                     extType = 'ppm'