* 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 09039f5..b82efce 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 d0a07fa..6524bc1 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