Stop ignoring Io exceptions
[hcoop/domtool2.git] / src / main.sml
index d57b867..4539b65 100644 (file)
@@ -576,7 +576,7 @@ fun requestListMailboxes domain =
             case m of
                 MsgMailboxes users => (Msg.send (bio, MsgOk);
                                        Vmail.Listing users)
-              | MsgError s => Vmail.Error ("Creation failed: " ^ s)
+              | MsgError s => Vmail.Error ("Listing failed: " ^ s)
               | _ => Vmail.Error "Unexpected server reply.")
        before OpenSSL.close bio
     end
@@ -939,7 +939,9 @@ fun regenerate context =
                else
                    ()
            end
-           handle IO.Io _ => ()
+           handle IO.Io {name, function, ...} =>
+                  (print ("IO error processing user " ^ user ^ ": " ^ function ^ ": " ^ name ^ "\n");
+                   ok := false)
                 | OS.SysErr (s, _) => (print ("System error processing user " ^ user ^ ": " ^ s ^ "\n");
                                        ok := false)
                 | ErrorMsg.Error => (ErrorMsg.reset ();
@@ -1361,7 +1363,8 @@ fun service () =
                                               SOME "Invalid password; may only contain printable, non-space characters")
                                          else if not (Domain.yourPath mailbox) then
                                              ("User wasn't authorized to add a mailbox at " ^ mailbox,
-                                              SOME "You're not authorized to use that mailbox location.")
+                                              SOME ("You're not authorized to use that mailbox location. ("
+                                                    ^ mailbox ^ ")"))
                                          else
                                              case Vmail.add {requester = user,
                                                              domain = domain, user = emailUser,