diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-11-06 15:20:09 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-11-06 15:20:09 +0000 |
commit | 3d013ccac70a281416dccbb6757f76818222cbba (patch) | |
tree | b44b7bc95d660905770332e3f649cae28ed8921d /net-analyzer/pnp4nagios/files | |
parent | 6003fc7a6eda56862fcff321f47e40cd34e60098 (diff) |
gentoo auto-resync : 06:11:2022 - 15:20:09
Diffstat (limited to 'net-analyzer/pnp4nagios/files')
-rw-r--r-- | net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_compat.patch | 53 | ||||
-rw-r--r-- | net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_php80.patch | 42 |
2 files changed, 95 insertions, 0 deletions
diff --git a/net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_compat.patch b/net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_compat.patch new file mode 100644 index 000000000000..21f9c89ed94f --- /dev/null +++ b/net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_compat.patch @@ -0,0 +1,53 @@ +# https://github.com/Tontonitch/pnp4nagios/commits/master + +diff --git a/share/pnp/application/views/graph_content.php b/share/pnp/application/views/graph_content.php +index 3ea99dc0..00469ce0 100644 +--- a/share/pnp/application/views/graph_content.php ++++ b/share/pnp/application/views/graph_content.php +@@ -88,7 +88,8 @@ + # treated like a url fragment when zooming + $gid = array(); + parse_str(ltrim($this->url, '?'), $gid); +- $gid = htmlentities("?host=".urlencode($gid["host"])."&srv=".urlencode($gid["srv"])); ++ $srv = isset($gid['srv']) ? $gid['srv'] : ''; ++ $gid = htmlentities("?host=".urlencode($gid["host"])."&srv=".urlencode($srv)); + + echo "<div start=".$value['TIMERANGE']['start']." end=".$value['TIMERANGE']['end']." style=\"width:".$value['GRAPH_WIDTH']."px; height:".$value['GRAPH_HEIGHT']."px; position:absolute; top:33px\" class=\"graph\" id=\"".$gid."\" ></div>"; + +diff --git a/share/pnp/application/vendor/fpdf/fpdf.php b/share/pnp/application/vendor/fpdf/fpdf.php +index cfc09593..efb53b4e 100755 +--- a/share/pnp/application/vendor/fpdf/fpdf.php ++++ b/share/pnp/application/vendor/fpdf/fpdf.php +@@ -1040,8 +1040,11 @@ protected function _dochecks() + if(ini_get('mbstring.func_overload') & 2)
+ $this->Error('mbstring overloading must be disabled');
+ // Ensure runtime magic quotes are disabled
+- if(get_magic_quotes_runtime())
+- @set_magic_quotes_runtime(0);
++# if(get_magic_quotes_runtime())
++# @set_magic_quotes_runtime(0);
++ if (PHP_VERSION_ID < 70400 && get_magic_quotes_runtime()) {
++ set_magic_quotes_runtime(0);
++ }
+ }
+
+ protected function _checkoutput()
+diff --git a/share/pnp/application/vendor/fpdf/fpdi_pdf_parser.php b/share/pnp/application/vendor/fpdf/fpdi_pdf_parser.php +index 9e6d521a..c044f200 100755 +--- a/share/pnp/application/vendor/fpdf/fpdi_pdf_parser.php ++++ b/share/pnp/application/vendor/fpdf/fpdi_pdf_parser.php +@@ -305,6 +305,7 @@ protected function _getPageRotation($obj) + }
+
+ $res = $this->_getPageRotation($obj[1][1]['/Parent']);
++ if(false == $res) return false;
+ if ($res[0] == pdf_parser::TYPE_OBJECT)
+ return $res[1];
+
+@@ -344,4 +345,4 @@ protected function _readPages(&$pages, &$result) + }
+ }
+ }
+-} +\ No newline at end of file ++}
diff --git a/net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_php80.patch b/net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_php80.patch new file mode 100644 index 000000000000..2407bb6c51e9 --- /dev/null +++ b/net-analyzer/pnp4nagios/files/pnp4nagios-0.6.26_p20221106_php80.patch @@ -0,0 +1,42 @@ +diff --git a/lib/kohana/system/core/utf8.php b/lib/kohana/system/core/utf8.php +index 9f20f42..b349c68 100644 +--- a/lib/kohana/system/core/utf8.php ++++ b/lib/kohana/system/core/utf8.php +@@ -49,17 +49,6 @@ if ( ! extension_loaded('iconv')) + ); + } + +-if (extension_loaded('mbstring') AND (ini_get('mbstring.func_overload') & MB_OVERLOAD_STRING)) +-{ +- trigger_error +- ( +- 'The <a href="http://php.net/mbstring">mbstring</a> extension is overloading PHP\'s native string functions. '. +- 'Disable this by setting mbstring.func_overload to 0, 1, 4 or 5 in php.ini or a .htaccess file.'. +- 'This application cannot be run without UTF-8 support.', +- E_USER_ERROR +- ); +-} +- + // Check PCRE support for Unicode properties such as \p and \X. + $ER = error_reporting(0); + define('PCRE_UNICODE_PROPERTIES', (bool) preg_match('/^\pL$/u', 'ñ')); +@@ -740,4 +729,4 @@ final class utf8 { + return _from_unicode($arr); + } + +-} // End utf8 +\ No newline at end of file ++} // End utf8 +diff --git a/share/pnp/application/models/data.php b/share/pnp/application/models/data.php +index 576c8ec..20cdade 100644 +--- a/share/pnp/application/models/data.php ++++ b/share/pnp/application/models/data.php +@@ -266,7 +266,7 @@ class Data_Model extends System_Model + $xml = array(); + if (file_exists($xmlfile)) { + libxml_use_internal_errors(TRUE); +- libxml_clear_errors(TRUE); ++ libxml_clear_errors(); + if(! $xml = simplexml_load_file($xmlfile) ){; + if( $throw_exception == TRUE ){ + $errors = '<br>'; |