[SerialICE] New patch to review for serialice: Cleanup on walk_post_hooks

Kyösti Mälkki (kyosti.malkki@gmail.com) gerrit at coreboot.org
Fri Jun 3 17:54:56 CEST 2016


Kyösti Mälkki (kyosti.malkki at gmail.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15061

-gerrit

commit 16fddc03ecb5be3741f35409b67805e55259b564
Author: Kyösti Mälkki <kyosti.malkki at gmail.com>
Date:   Fri Jun 3 14:30:24 2016 +0300

    Cleanup on walk_post_hooks
    
    We always walk the complete list of post_hooks, as logging of the
    operations happens at the end.
    
    Also no return code from this function.
    
    Change-Id: I5934174f4d4fc02764170c97fb518330beaeab74
    Signed-off-by: Kyösti Mälkki <kyosti.malkki at gmail.com>
---
 SerialICE/simba/hooks.lua | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/SerialICE/simba/hooks.lua b/SerialICE/simba/hooks.lua
index fcb0912..2ce5f36 100644
--- a/SerialICE/simba/hooks.lua
+++ b/SerialICE/simba/hooks.lua
@@ -110,20 +110,18 @@ end
 
 function walk_post_hooks(list, action)
 	if list == nil or list.list == nil then
-		return false
+		return
 	end
-	local logged = false
 	local l = list.list
 	local f = nil
 
-	while l and not logged do
+	while l do
 		f = l.hook
 		if list.match_filter(f, action) then
 			if f.post and f.post(f, action) then
 				if not f.raw then
 					action.logged_post = f
 				end
-				logged = false
 			end
 		end
 		l = l.next



More information about the SerialICE mailing list