From 6d41e220e69528d5394d93e7fac71e636b03357c Mon Sep 17 00:00:00 2001 From: morloi Date: Tue, 3 Apr 2018 15:52:45 +0200 Subject: [PATCH] Update for php 7.2 compatibility issue Getting rid of "Warning: count(): Parameter must be an array or an object that implements Countable" that Php 7.2 throws --- lib/xmlrpc.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/xmlrpc.inc b/lib/xmlrpc.inc index 7123184..80bdf72 100644 --- a/lib/xmlrpc.inc +++ b/lib/xmlrpc.inc @@ -2684,7 +2684,7 @@ xmlrpc_encode_entitites($this->errstr, $GLOBALS['xmlrpc_internalencoding'], $cha xml_set_default_handler($parser, 'xmlrpc_dh'); // first error check: xml not well formed - if(!xml_parse($parser, $data, count($data))) + if(!xml_parse($parser, $data, 1)) { // thanks to Peter Kocks if((xml_get_current_line_number($parser)) == 1) @@ -3919,4 +3919,4 @@ xmlrpc_encode_entitites($this->errstr, $GLOBALS['xmlrpc_internalencoding'], $cha } } -?> \ No newline at end of file +?> -- 2.43.0