Author: gcasa
Date: Wed Apr 6 23:41:41 2016
New Revision: 39639
URL: http://svn.gna.org/viewcvs/gnustep?rev=39639&view=rev
Log:
Fixed crash when loading bad help file.
Modified:
apps/gworkspace/trunk/ChangeLog
apps/gworkspace/trunk/GWorkspace/GWorkspace.m
Modified: apps/gworkspace/trunk/ChangeLog
URL:
http://svn.gna.org/viewcvs/gnustep/apps/gworkspace/trunk/ChangeLog?rev=39639&r1=39638&r2=39639&view=diff
==============================================================================
--- apps/gworkspace/trunk/ChangeLog (original)
+++ apps/gworkspace/trunk/ChangeLog Wed Apr 6 23:41:41 2016
@@ -1,3 +1,9 @@
+2016-04-06 17:41-EDT Gregory John Casamento <[email protected]>
+
+ * GWorkspace/GWorkspace.m: Add exception handler when loading
+ help file. Still print out issue, but do not crash and end
+ up in an inconsistent state.
+
2016-03-24 Riccardo Mottola <[email protected]>
* GWorkspace/Finder/Modules/FModuleAnnotations/FModuleAnnotations.m
Modified: apps/gworkspace/trunk/GWorkspace/GWorkspace.m
URL:
http://svn.gna.org/viewcvs/gnustep/apps/gworkspace/trunk/GWorkspace/GWorkspace.m?rev=39639&r1=39638&r2=39639&view=diff
==============================================================================
--- apps/gworkspace/trunk/GWorkspace/GWorkspace.m (original)
+++ apps/gworkspace/trunk/GWorkspace/GWorkspace.m Wed Apr 6 23:41:41 2016
@@ -967,9 +967,17 @@
if ([fm fileExistsAtPath: helpPath])
{
- NSAttributedString *help = [[NSAttributedString alloc] initWithPath:
helpPath
-
documentAttributes: NULL];
- return AUTORELEASE (help);
+ NS_DURING
+ {
+ NSAttributedString *help = [[NSAttributedString alloc]
initWithPath: helpPath
+
documentAttributes: NULL];
+ return AUTORELEASE (help);
+ }
+ NS_HANDLER
+ {
+ return nil;
+ }
+ NS_ENDHANDLER;
}
}
_______________________________________________
Gnustep-cvs mailing list
[email protected]
https://mail.gna.org/listinfo/gnustep-cvs