diff --git a/lib/kc3/0.1/httpd.kc3 b/lib/kc3/0.1/httpd.kc3
index c7bfa6c..f276198 100644
--- a/lib/kc3/0.1/httpd.kc3
+++ b/lib/kc3/0.1/httpd.kc3
@@ -123,11 +123,10 @@ defmodule HTTPd do
def server = fn (host, port) {
def socket = Socket.listen(host, port)
daemonize()
- i = 1
- while i > 0 do
+ threads = List.map(List.count(1), fn (x) {
Thread.new(server_thread)
- i = i - 1
- end
+ })
+ List.map(threads, Thread.delete)
}
def main = fn {