diff -u cacti-0.8.6j/debian/changelog cacti-0.8.6j/debian/changelog --- cacti-0.8.6j/debian/changelog +++ cacti-0.8.6j/debian/changelog @@ -1,3 +1,11 @@ +cacti (0.8.6j-1.1ubuntu1.2) gutsy-proposed; urgency=low + + * Cacti FTBFS (LP: #194687) + + debian/patches/11_php_self_nonstandard_dir.dpatch + - Cacti frontend fails with 'Invalid PHP_SELF Path'. + + -- Emanuele Gentili Mon, 31 Mar 2008 00:03:37 +0200 + cacti (0.8.6j-1.1ubuntu0.2) gutsy-security; urgency=low * SECURITY UPDATE: (LP: #192199) diff -u cacti-0.8.6j/debian/patches/00list cacti-0.8.6j/debian/patches/00list --- cacti-0.8.6j/debian/patches/00list +++ cacti-0.8.6j/debian/patches/00list @@ -10,0 +11 @@ +11_php_self_nonstandard_dir.dpatch only in patch2: unchanged: --- cacti-0.8.6j.orig/debian/patches/11_php_self_nonstandard_dir.dpatch +++ cacti-0.8.6j/debian/patches/11_php_self_nonstandard_dir.dpatch @@ -0,0 +1,19 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 11_php_self_nonstandard_dir.dpatch by Emanuele Gentili +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ +diff -urNad cacti-0.8.6j~/include/config.php cacti-0.8.6j/include/config.php +--- cacti-0.8.6j~/include/config.php 2008-03-31 00:01:11.000000000 +0200 ++++ cacti-0.8.6j/include/config.php 2008-03-31 00:02:46.000000000 +0200 +@@ -84,7 +84,7 @@ + /* Sanity Check on "Corrupt" PHP_SELF */ + if ((!is_file($_SERVER["PHP_SELF"])) && (!is_file($config["base_path"] . '/' . $_SERVER["PHP_SELF"]))) { + if (!is_file($_SERVER["DOCUMENT_ROOT"] . $_SERVER["PHP_SELF"])) { +- if (!((is_file($_SERVER["SCRIPT_FILENAME"])) && (substr_count($_SERVER["SCRIPT_FILENAME"], $_SERVER["PHP_SELF"])))) { ++ if (!((is_file($_SERVER["SCRIPT_FILENAME"])) && (substr_count($_SERVER["SCRIPT_FILENAME"], basename($_SERVER["PHP_SELF"]))))) { + echo "\nInvalid PHP_SELF Path\n"; + exit; + }