Opened 13 years ago

Closed 13 years ago

#1383 closed defect (fixed)

wxGUI crashes if settings file .grasswx6 does not exist

Reported by: mmetz Owned by: martinl
Priority: blocker Milestone: 6.4.2
Component: wxGUI Version: svn-releasebranch64
Keywords: wxGUI, settings Cc: grass-dev@…
CPU: All Platform: All

Description

The wxGUI crashes quite ungracefully if .grasswx6 does not exist

  File "/home/metz/src/grass-6.4.svn/dist.x86_64-unknown-linux-gnu/etc/wxpython/gui_modules/preferences.py", line 698, in _readFile
    file = open(filename, "r")
IOError: [Errno 2] No such file or directory: '/home/metz/.grasswx6'
Error in GUI startup. If necessary, please
report this error to the GRASS developers.

The failing function _readFile does not make sense to me because it tries to read the file even if it could not be opened. A simple test if the file exists fixes the problem.

Change History (2)

comment:1 by martinl, 13 years ago

Cc: grass-dev@… added
Owner: changed from grass-dev@… to martinl
Status: newassigned

Right, hopefully fixed in r46585 (backported to G64 in r46586).

in reply to:  1 comment:2 by mmetz, 13 years ago

Resolution: fixed
Status: assignedclosed

Replying to martinl:

Right, hopefully fixed in r46585 (backported to G64 in r46586).

Works now, thanks.

Note: See TracTickets for help on using tickets.