krishnanadh / rpms / rasdaemon

Forked from rpms/rasdaemon a year ago
Clone
ac32bf
From 5dd11c60b84294a3c6ce5ccb0db726b3dce35b10 Mon Sep 17 00:00:00 2001
ac32bf
From: Seiichi Ikarashi <s.ikarashi@jp.fujitsu.com>
ac32bf
Date: Tue, 26 May 2015 11:59:36 -0300
ac32bf
Subject: [PATCH 07/13] rasdaemon: properly pring message strings in
ac32bf
 decode_bitfield()
ac32bf
ac32bf
Fix decode_bitfield() so that it does print message strings from the struct
ac32bf
field table.
ac32bf
ac32bf
Signed-off-by: Seiichi Ikarashi <s.ikarashi@jp.fujitsu.com>
ac32bf
Signed-off-by: Aristeu Rozanski <aris@redhat.com>
ac32bf
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
ac32bf
---
ac32bf
 bitfield.c | 3 ++-
ac32bf
 1 file changed, 2 insertions(+), 1 deletion(-)
ac32bf
ac32bf
diff --git a/bitfield.c b/bitfield.c
ac32bf
index 1dda30d..d6931c9 100644
ac32bf
--- a/bitfield.c
ac32bf
+++ b/bitfield.c
ac32bf
@@ -84,7 +84,8 @@ void decode_bitfield(struct mce_event *e, uint64_t status,
ac32bf
 				continue;
ac32bf
 			mce_snprintf(e->error_msg, "<%u:%llx>",
ac32bf
 				     f->start_bit, (long long)v);
ac32bf
-		}
ac32bf
+		} else
ac32bf
+			mce_snprintf(e->error_msg, "%s", s);
ac32bf
 	}
ac32bf
 }
ac32bf
 
ac32bf
-- 
ac32bf
1.8.3.1
ac32bf