From 825175b91b7aed267b3aafab4b36cede12b12ddf Mon Sep 17 00:00:00 2001 From: hfrenzel-guest Date: Fri, 5 Mar 2010 11:56:40 +0000 Subject: [PATCH] git-svn-id: svn://svn.debian.org/svn/pkg-nagios/nagvis/trunk@1834 98d490a6-b407-0410-aaaa-fdee166ba3f5 --- debian/changelog | 7 ++- debian/config | 1 + debian/control | 2 +- debian/lintian-overrides | 2 - debian/patches/00list | 3 +- .../{10_pathnames.dpatch => config.dpatch} | 4 +- debian/patches/fix-get_class-object.dpatch | 49 +++++++++++++++++++ debian/patches/php5.3-deprecated-ereg.dpatch | 2 +- .../visibility_magic-set-method.dpatch | 2 +- 9 files changed, 60 insertions(+), 12 deletions(-) delete mode 100644 debian/lintian-overrides rename debian/patches/{10_pathnames.dpatch => config.dpatch} (97%) create mode 100755 debian/patches/fix-get_class-object.dpatch diff --git a/debian/changelog b/debian/changelog index 7d2e3d9..9f2a855 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,8 @@ -nagvis (1:1.4.6-1) UNRELEASED; urgency=low - - * (NOT RELEASED YET) +nagvis (1:1.4.6-1) unstable; urgency=low [ Hendrik Frenzel ] - * New upstream version + * New upstream version (Closes: #533379) + * Fixed desctiption (Closes: #560705) * Patched deprecated ereg to preg_match to get them work with php 5.3+ -- Hendrik Frenzel Fri, 19 Feb 2010 12:33:48 +0100 diff --git a/debian/config b/debian/config index 7f21a9e..7e02dfc 100644 --- a/debian/config +++ b/debian/config @@ -1,4 +1,5 @@ #!/bin/sh +set -e . /usr/share/debconf/confmodule diff --git a/debian/control b/debian/control index 75f01d9..2a19df7 100644 --- a/debian/control +++ b/debian/control @@ -23,7 +23,7 @@ Description: Visualization addon for Nagios * Display of single Hosts or Services * Display the state of a Host dependent on the state of its services ("recognize services") - * Visualize a complete Host- oder Servicegroup with one icon + * Visualization of Host- oder Servicegroups with one icon * Define Sub-Map icons wich represent a complete NagVis Map of Hosts/Services/Groups in one icon (drill down) * Visualization of complete IT Processes using self drawn graphics diff --git a/debian/lintian-overrides b/debian/lintian-overrides deleted file mode 100644 index 1b94a80..0000000 --- a/debian/lintian-overrides +++ /dev/null @@ -1,2 +0,0 @@ -nagvis: package-contains-empty-directory usr/share/nagvis/htdocs/nagvis/images/shapes/ - diff --git a/debian/patches/00list b/debian/patches/00list index e1c8019..ca25319 100644 --- a/debian/patches/00list +++ b/debian/patches/00list @@ -1,3 +1,4 @@ -10_pathnames.dpatch +config php5.3-deprecated-ereg visibility_magic-set-method +fix-get_class-object diff --git a/debian/patches/10_pathnames.dpatch b/debian/patches/config.dpatch similarity index 97% rename from debian/patches/10_pathnames.dpatch rename to debian/patches/config.dpatch index 2d0e76c..b02c730 100755 --- a/debian/patches/10_pathnames.dpatch +++ b/debian/patches/config.dpatch @@ -1,8 +1,8 @@ #! /bin/sh /usr/share/dpatch/dpatch-run -## 10_pathnames.dpatch by Wolfgang Barth +## config.dpatch by Wolfgang Barth ## ## All lines beginning with `## DP:' are a description of the patch. -## DP: No description. +## DP: changes default configs @DPATCH@ diff -urNad nagvis-1.4.6~/etc/nagvis.ini.php-sample nagvis-1.4.6/etc/nagvis.ini.php-sample diff --git a/debian/patches/fix-get_class-object.dpatch b/debian/patches/fix-get_class-object.dpatch new file mode 100755 index 0000000..c5d2274 --- /dev/null +++ b/debian/patches/fix-get_class-object.dpatch @@ -0,0 +1,49 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## fix-get_class-object.dpatch by Hendrik Frenzel +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: add is_object() to check for object before use get_class() + +@DPATCH@ +diff -urNad nagvis-1.4.6~/nagvis/includes/classes/GlobalHeaderMenu.php nagvis-1.4.6/nagvis/includes/classes/GlobalHeaderMenu.php +--- nagvis-1.4.6~/nagvis/includes/classes/GlobalHeaderMenu.php 2010-02-04 21:51:13.000000000 +0100 ++++ nagvis-1.4.6/nagvis/includes/classes/GlobalHeaderMenu.php 2010-03-05 11:52:13.000000000 +0100 +@@ -84,7 +84,7 @@ + */ + public function replaceDynamicMacros() { + // Replace some special macros +- if($this->OBJPAGE !== null && get_class($this->OBJPAGE) == 'NagVisMapCfg') { ++ if($this->OBJPAGE !== null && (is_object($this->OBJPAGE) && get_class($this->OBJPAGE) == 'NagVisMapCfg')) { + $arrKeys[] = '[current_map]'; + $arrKeys[] = '[current_map_alias]'; + $arrVals[] = $this->OBJPAGE->getName(); +@@ -122,7 +122,7 @@ + } + + // auto select current map +- if(get_class($this->OBJPAGE) == 'NagVisMapCfg' && ($mapName == $this->OBJPAGE->getName() || $mapName == '__automap' && isset($_GET['automap']))) { ++ if((is_object($this->OBJPAGE) && get_class($this->OBJPAGE) == 'NagVisMapCfg') && ($mapName == $this->OBJPAGE->getName() || $mapName == '__automap' && isset($_GET['automap']))) { + $sReplaceObj = str_replace('[selected]','selected="selected"',$sReplaceObj); + } else { + $sReplaceObj = str_replace('[selected]','',$sReplaceObj); +@@ -138,7 +138,7 @@ + } + + // Select overview in header menu when no map shown +- if(get_class($this->OBJPAGE) != 'NagVisMapCfg') { ++ if((is_object($this->OBJPAGE) && get_class($this->OBJPAGE) != 'NagVisMapCfg')) { + $this->code = str_replace('[selected]','selected="selected"', $this->code); + } + +diff -urNad nagvis-1.4.6~/nagvis/includes/classes/NagVisFrontend.php nagvis-1.4.6/nagvis/includes/classes/NagVisFrontend.php +--- nagvis-1.4.6~/nagvis/includes/classes/NagVisFrontend.php 2010-02-04 21:51:13.000000000 +0100 ++++ nagvis-1.4.6/nagvis/includes/classes/NagVisFrontend.php 2010-03-05 11:44:49.000000000 +0100 +@@ -86,7 +86,7 @@ + $prop['languageRoot'] = 'nagvis'; + + // Only do this, when a map needs to be displayed +- if($this->MAPCFG !== null && get_class($this->MAPCFG) != '') { ++ if($this->MAPCFG !== null && (is_object($this->MAPCFG) && get_class($this->MAPCFG) != '')) { + $prop['allowedUsers'] = $this->MAPCFG->getValue('global',0, 'allowed_user'); + } + diff --git a/debian/patches/php5.3-deprecated-ereg.dpatch b/debian/patches/php5.3-deprecated-ereg.dpatch index 815b3f5..7f83baf 100755 --- a/debian/patches/php5.3-deprecated-ereg.dpatch +++ b/debian/patches/php5.3-deprecated-ereg.dpatch @@ -2,7 +2,7 @@ ## php5.3-deprecated-ereg.dpatch by Hendrik Frenzel ## ## All lines beginning with `## DP:' are a description of the patch. -## DP: No description. +## DP: changes deprecated ereg() to preg_match() for use with php >= 5.3 @DPATCH@ diff -urNad nagvis-1.4.6~/nagvis/includes/classes/GlobalMainCfg.php nagvis-1.4.6/nagvis/includes/classes/GlobalMainCfg.php diff --git a/debian/patches/visibility_magic-set-method.dpatch b/debian/patches/visibility_magic-set-method.dpatch index b76d11d..f2e9187 100755 --- a/debian/patches/visibility_magic-set-method.dpatch +++ b/debian/patches/visibility_magic-set-method.dpatch @@ -2,7 +2,7 @@ ## visibility_magic-set-method.dpatch by Hendrik Frenzel ## ## All lines beginning with `## DP:' are a description of the patch. -## DP: No description. +## DP: make magicmethod __set public o avoid error @DPATCH@ diff -urNad nagvis-1.4.6~/nagvis/includes/classes/validator/GlobalValidatorInteger.php nagvis-1.4.6/nagvis/includes/classes/validator/GlobalValidatorInteger.php -- 2.30.2