Catch every Throwable in update methods, since

FESI may throw Errors at us
This commit is contained in:
hns 2001-08-23 14:02:12 +00:00
parent 39a561ff2b
commit c2605e72b6
3 changed files with 4 additions and 4 deletions

View file

@ -69,7 +69,7 @@ public class Action implements Updatable {
reader.close (); reader.close ();
String content = new String (cbuf); String content = new String (cbuf);
update (content); update (content);
} catch (Exception filex) { } catch (Throwable filex) {
app.logEvent ("*** Error reading action file "+file+": "+filex); app.logEvent ("*** Error reading action file "+file+": "+filex);
} }

View file

@ -97,7 +97,7 @@ public class FunctionFile implements Updatable {
EvaluationSource es = new FileEvaluationSource(file.getPath(), null); EvaluationSource es = new FileEvaluationSource(file.getPath(), null);
updateRequestEvaluator (reval, fr, es); updateRequestEvaluator (reval, fr, es);
} catch (Exception ignore) {} } catch (Throwable ignore) {}
} }
} }

View file

@ -144,7 +144,7 @@ public class Template extends Action {
pfunc = parseFunction (name, pfunc = parseFunction (name,
"arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10", "arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10",
body+"\r\nreturn null;\r\n"); body+"\r\nreturn null;\r\n");
} catch (Exception x) { } catch (Throwable x) {
String message = x.getMessage (); String message = x.getMessage ();
pfunc = new ErrorFeedback (name, message); pfunc = new ErrorFeedback (name, message);
} }
@ -152,7 +152,7 @@ public class Template extends Action {
psfunc = parseFunction (fname, psfunc = parseFunction (fname,
"arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10", "arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10",
"res.pushStringBuffer(); "+body+"\r\nreturn res.popStringBuffer();\r\n"); "res.pushStringBuffer(); "+body+"\r\nreturn res.popStringBuffer();\r\n");
} catch (Exception x) { } catch (Throwable x) {
String message = x.getMessage (); String message = x.getMessage ();
psfunc = new ErrorFeedback (fname, message); psfunc = new ErrorFeedback (fname, message);
} }