Ver código fonte

g.gui: ends with fatal error, when GUI is not available

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@66913 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 9 anos atrás
pai
commit
8538927c4f
1 arquivos alterados com 3 adições e 0 exclusões
  1. 3 0
      general/g.gui/main.c

+ 3 - 0
general/g.gui/main.c

@@ -102,6 +102,9 @@ int main(int argc, char *argv[])
     }
 
     sprintf(progname, "%s/gui/wxpython/wxgui.py", G_gisbase());
+    if (access(progname, F_OK) == -1)
+        G_fatal_error(_("Your installation doesn't include GUI, exiting."));
+                      
     if (fglaunch->answer) {
         G_message(_("Launching <%s> GUI, please wait..."), type->answer);
         if (rc_file->answer) {