cleaned up error message and save prefs as text now
original commit: 7e3444f3be8f6521b2c7d361e4e5f13c9dfb8579
This commit is contained in:
parent
449cafbff3
commit
aed196dd52
|
@ -175,15 +175,17 @@
|
|||
(lambda (p)
|
||||
(mzlib:pretty-print:pretty-print
|
||||
(hash-table-map preferences marshall-pref) p))
|
||||
'truncate)
|
||||
'truncate 'text)
|
||||
(mred:debug:printf 'prefs "saved user preferences"))))
|
||||
|
||||
(mred:exit:insert-exit-callback
|
||||
(lambda ()
|
||||
(with-handlers ((void (lambda (exn)
|
||||
(with-handlers ([(lambda (x) #t)
|
||||
(lambda (exn)
|
||||
(mred:gui-utils:message-box
|
||||
(format "exception raied while saving prefs: ~a"
|
||||
(exn-message exn))))))
|
||||
(format "error while saving prefs: ~a"
|
||||
(exn-message exn))
|
||||
"Saving Prefs"))])
|
||||
(save-user-preferences))))
|
||||
|
||||
(define read-user-preferences
|
||||
|
@ -218,7 +220,8 @@
|
|||
(wx:message-box (format "found bad pref: ~n~a" input)
|
||||
"Preferences"))])
|
||||
(let loop ([input (call-with-input-file preferences-filename
|
||||
read)])
|
||||
read
|
||||
'text)])
|
||||
(cond
|
||||
[(pair? input)
|
||||
(let/ec k
|
||||
|
|
Loading…
Reference in New Issue
Block a user