Skip to contentSkip to conversation

rasdaemon: fix build error in register_ns_ev_decoder if the sqlite3 is not enabled

PATCH Applied Shiju Jose 2 participants 2 messages Mar 9, 2021 – May 26, 2021 EDAC-core

lore
Share & tools
lore

Shiju Jose

author
#0 lore raw

PATCH 1/1 rasdaemon: fix build error in register_ns_ev_decoder if the sqlite3 is not enabled

ns_ev_decoder->stmt_dec_record = NULL; in the register_ns_ev_decoder() should be under #ifdef HAVE_SQLITE3 to fix the compilation error when build without the configure option --enable-sqlite3.

---
 ras-non-standard-handler.c | 2 ++
 1 file changed, 2 insertions(+)
ras-non-standard-handler.c +2 -0
index 1862335..8d9802d 100644
@@ -74,7 +74,9 @@ int register_ns_ev_decoder(struct ras_ns_ev_decoder *ns_ev_decoder)
 		return -1;
 
 	ns_ev_decoder->next = NULL;
+#ifdef HAVE_SQLITE3
 	ns_ev_decoder->stmt_dec_record = NULL;
+#endif
 	if (!ras_ns_ev_dec_list) {
 		ras_ns_ev_dec_list = ns_ev_decoder;
 	} else {
Signature · 1 line
2.17.1
#1 lore raw

Em Tue, 9 Mar 2021 16:18:56 +0000
Shiju Jose <[email protected]> escreveu:

Quoted 5 lines

ns_ev_decoder->stmt_dec_record = NULL; in the register_ns_ev_decoder() should be under #ifdef HAVE_SQLITE3 to fix the compilation error when build without the configure option --enable-sqlite3.

Applied, thanks!

Quoted 9 lines
---
 ras-non-standard-handler.c | 2 ++
 1 file changed, 2 insertions(+)
ras-non-standard-handler.c +0 -0
index 1862335..8d9802d 100644

ras-non-standard-handler.c int register_ns_ev_decoder(struct ras_ns_ev_decoder *ns_ev_decoder) · line 82

Quoted 9 lines
ras-non-standard-handler.c +2 -0
@@ -74,7 +74,9 @@ int register_ns_ev_decoder(struct ras_ns_ev_decoder *ns_ev_decoder)
 		return -1;
 
 	ns_ev_decoder->next = NULL;
+#ifdef HAVE_SQLITE3
 	ns_ev_decoder->stmt_dec_record = NULL;
+#endif
 	if (!ras_ns_ev_dec_list) {
 		ras_ns_ev_dec_list = ns_ev_decoder;
 	} else {

Thanks,
Mauro