add parsers for memory info and system info
[logparse.git] / logparse / parsers / httpd.py
index 7175ea8326fd582fd06b544478bb37950ac13a9e..d0e800c896f75a451768ff809657d2e454939842 100644 (file)
@@ -60,18 +60,20 @@ def parse_log():
     if (ips != None):
         logger.debug("Parsing client statistics")
         client_data = Data()
-        client_data.items = orderbyfreq(ips)
-        client_data.subtitlte = plural(" client", str(len(ips)))
+        client_data.items = ips
+        client_data.orderbyfreq()
+        client_data.subtitle = plural(" client", str(len(ips)))
         client_data.truncl(config.prefs['maxlist'])
         section.append_data(client_data)
     if (useragents != None):
         logger.debug("Parsing user agent statistics")
         ua_data = Data()
-        ua_data.items = orderbyfreq(useragents)
+        ua_data.items = useragents
+        ua_data.orderbyfreq()
         n_ua = str(len(ua_data.items))
         ua_data.truncl(config.prefs['maxlist'])
         ua_data.subtitle = plural(" user agent", n_ua)
-        section.append_data(client_data)
+        section.append_data(ua_data)
 
     section.append_data(Data(data_h + " transferred"))
     section.append_data(Data(plural(" error", e)))