From 901dc04a2121bc902fb673bc41bdaf5dee69df5e Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Mon, 4 Aug 2014 01:27:22 -0400 Subject: [PATCH] fix build against latest json-c --- rsyslog-7.4.10-json-c-fix.patch | 12 ++++++++++++ rsyslog.spec | 4 ++++ 2 files changed, 16 insertions(+) create mode 100644 rsyslog-7.4.10-json-c-fix.patch diff --git a/rsyslog-7.4.10-json-c-fix.patch b/rsyslog-7.4.10-json-c-fix.patch new file mode 100644 index 0000000..4a6437a --- /dev/null +++ b/rsyslog-7.4.10-json-c-fix.patch @@ -0,0 +1,12 @@ +diff -up rsyslog-7.4.10/plugins/mmjsonparse/mmjsonparse.c.jsonfix rsyslog-7.4.10/plugins/mmjsonparse/mmjsonparse.c +--- rsyslog-7.4.10/plugins/mmjsonparse/mmjsonparse.c.jsonfix 2014-08-04 01:23:23.434286740 -0400 ++++ rsyslog-7.4.10/plugins/mmjsonparse/mmjsonparse.c 2014-08-04 01:24:07.617956596 -0400 +@@ -146,7 +146,7 @@ processJSON(instanceData *pData, msg_t * + + err = pData->tokener->err; + if(err != json_tokener_continue) +- errMsg = json_tokener_errors[err]; ++ errMsg = json_tokener_get_err(err); + else + errMsg = "Unterminated input"; + } else if((size_t)pData->tokener->char_offset < lenBuf) diff --git a/rsyslog.spec b/rsyslog.spec index d4a5784..6f1e23a 100644 --- a/rsyslog.spec +++ b/rsyslog.spec @@ -31,6 +31,8 @@ Patch5: rsyslog-7.4.7-numeric-uid.patch Patch6: rsyslog-7.4.7-atomicops.patch # merged upstream Patch8: rsyslog-7.4.8-bz1026804-imjournal-message-loss.patch +# json_tokener_errors is gone in current json-c +Patch9: rsyslog-7.4.10-json-c-fix.patch BuildRequires: bison BuildRequires: flex @@ -254,6 +256,7 @@ of source ports. %patch5 -p1 %patch6 -p1 %patch8 -p1 +%patch9 -p1 -b .jsonfix %build %ifarch sparc64 @@ -487,6 +490,7 @@ done %changelog * Mon Aug 04 2014 Tom Callaway - 7.4.10-3 - fix license handling +- fix build against latest json-c * Sun Jun 08 2014 Fedora Release Engineering - 7.4.10-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild