diff --git a/happstack-server.cabal b/happstack-server.cabal
--- a/happstack-server.cabal
+++ b/happstack-server.cabal
@@ -1,5 +1,5 @@
 Name:                happstack-server
-Version:             7.0.6
+Version:             7.0.7
 Synopsis:            Web related tools and services.
 Description:         Happstack Server provides an HTTP server and a rich set of functions for routing requests, handling query parameters, generating responses, working with cookies, serving files, and more. For in-depth documentation see the Happstack Crash Course <http://happstack.com/docs/crashcourse/index.html>
 License:             BSD3
diff --git a/src/Happstack/Server.hs b/src/Happstack/Server.hs
--- a/src/Happstack/Server.hs
+++ b/src/Happstack/Server.hs
@@ -79,7 +79,9 @@
                                          , simpleHTTPWithSocket'
                                          , bindPort
                                          , bindIPv4
-                                         , parseConfig)
+                                         , parseConfig
+                                         , waitForTermination
+                                         )
 import Happstack.Server.FileServe
 import Happstack.Server.Monads
 import Happstack.Server.Auth
diff --git a/src/Happstack/Server/SimpleHTTP.hs b/src/Happstack/Server/SimpleHTTP.hs
--- a/src/Happstack/Server/SimpleHTTP.hs
+++ b/src/Happstack/Server/SimpleHTTP.hs
@@ -227,6 +227,7 @@
          istty <- queryTerminal stdInput
          mv <- newEmptyMVar
          void $ installHandler softwareTermination (CatchOnce (putMVar mv ())) Nothing
+         void $ installHandler lostConnection      (CatchOnce (putMVar mv ())) Nothing
          case istty of
            True  -> void $ installHandler keyboardSignal (CatchOnce (putMVar mv ())) Nothing
            False -> return ()
