From 0b49411ce957b38fc2f286e09a5b904aadc62229 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Wed, 10 Aug 2016 16:19:00 +0000 Subject: Remove trailing whitespace --- Makefile | 2 +- snort-details-html.lsp | 2 +- snort-model.lua | 7 +++---- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 80e976b..eb5a765 100644 --- a/Makefile +++ b/Makefile @@ -7,7 +7,7 @@ APP_DIST=\ EXTRA_DIST=README Makefile config.mk -DISTFILES=$(APP_DIST) $(EXTRA_DIST) +DISTFILES=$(APP_DIST) $(EXTRA_DIST) TAR=tar diff --git a/snort-details-html.lsp b/snort-details-html.lsp index 35eebbe..2ed5770 100644 --- a/snort-details-html.lsp +++ b/snort-details-html.lsp @@ -8,7 +8,7 @@ html = require("acf.html") <% local header_level = htmlviewfunctions.displaysectionstart(data, page_info) %> <% local header_level2 = htmlviewfunctions.incrementheader(header_level) %> <% local header_level3 = htmlviewfunctions.incrementheader(header_level2) %> -<% +<% if #data.value == 0 then io.write("

No alerts found

") else diff --git a/snort-model.lua b/snort-model.lua index 6c633a3..7892ad3 100644 --- a/snort-model.lua +++ b/snort-model.lua @@ -1,4 +1,3 @@ --- acf model for displaying logfiles recusivly local mymodule = {} -- Load libraries @@ -21,11 +20,11 @@ function mymodule.getstatus() return modelfunctions.getstatus(processname, packagename, "Snort Status") end -function mymodule.get_startstop(self, clientdata) +function mymodule.get_startstop(self, clientdata) return modelfunctions.get_startstop(processname) end -function mymodule.startstop_service(self, startstop, action) +function mymodule.startstop_service(self, startstop, action) return modelfunctions.startstop_service(startstop, action) end @@ -69,7 +68,7 @@ function mymodule.read_alert() end --Start sorting priority-table local sorted_table = {} - for name,value in pairs(alertpriority) do + for name,value in pairs(alertpriority) do table.insert(sorted_table, {name=name, value=value}) end table.sort(sorted_table, function(a,b) return (a.name < b.name) end) -- cgit v1.2.3