(* HCoop Domtool (http://hcoop.sourceforge.net/)
- * Copyright (c) 2006, Adam Chlipala
+ * Copyright (c) 2006-2007, Adam Chlipala
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
OpenSSL.close bio
handle OpenSSL.OpenSSL _ => ();
loop ())
- | _ =>
+ | IO.Io {name, function, cause} =>
+ (print ("IO error: " ^ function ^ " for " ^ name ^ "\n");
+ app (fn x => print (x ^ "\n")) (SMLofNJ.exnHistory cause);
+ OpenSSL.close bio
+ handle OpenSSL.OpenSSL _ => ();
+ loop ())
+ | e =>
(print "Unknown exception in main loop!\n";
+ app (fn x => print (x ^ "\n")) (SMLofNJ.exnHistory e);
OpenSSL.close bio
handle OpenSSL.OpenSSL _ => ();
loop ())
OpenSSL.close bio
handle OpenSSL.OpenSSL _ => ();
loop ())
- | OS.SysErr (s, _) =>
- (print ("System error: "^ s ^ "\n");
+ | e as OS.SysErr (s, _) =>
+ (app (fn s => print (s ^ "\n")) (SMLofNJ.exnHistory e);
+ print ("System error: "^ s ^ "\n");
OpenSSL.close bio
handle OpenSSL.OpenSSL _ => ();
loop ())