* libs/httpd: Tuned Garbage Collection
authorSteven Barth <steven@midlink.org>
Mon, 23 Jun 2008 21:30:44 +0000 (21:30 +0000)
committerSteven Barth <steven@midlink.org>
Mon, 23 Jun 2008 21:30:44 +0000 (21:30 +0000)
libs/httpd/host/runluci
libs/httpd/luasrc/httpd.lua

index 09039f55398e9118188ba996d3ce74050de663e9..b82efce1c08cd35c711aa0a8bdcf46dfd208268e 100755 (executable)
@@ -7,6 +7,7 @@ require("luci.httpd.handler.luci")
 DOCROOT = arg[1]
 PORT = 8080
 
+collectgarbage("setpause", 150)
 
 serversocket = luci.httpd.Socket("0.0.0.0", PORT)
 
index d0a07faa70a42ab255fa94791f10642b13694b67..6524bc1de631d937ccb35f42025a18f7f79226a3 100644 (file)
@@ -118,10 +118,9 @@ function Daemon.step(self)
                        
                        if self.debug then
                                self:dprint(tostring(client[1]) .. " returned")
-                       end
-
-                       if not stat and self.debug then
-                               self:dprint("Error in " .. tostring(client[1]) .. " " .. err)
+                               if not stat then
+                                       self:dprint("Error in " .. tostring(client[1]) .. " " .. err)
+                               end
                        end
                end
        end