aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2014-05-07 15:50:27 -0400
committerjim-p <jimp@pfsense.org>2014-05-07 15:50:27 -0400
commita1db63c131fab7259d1bc865abd279c51d20bbce (patch)
tree1ac09199b780911c5ce9dacace0b5ef6410e7599
parentc6c75ae5466c3d1690d6973006bda7a2f77c167f (diff)
downloadpfsense-packages-a1db63c131fab7259d1bc865abd279c51d20bbce.tar.gz
pfsense-packages-a1db63c131fab7259d1bc865abd279c51d20bbce.tar.bz2
pfsense-packages-a1db63c131fab7259d1bc865abd279c51d20bbce.zip
Fix call-time pass-by-reference in System Patches, bump version
-rw-r--r--config/systempatches/system_patches.php2
-rw-r--r--config/systempatches/system_patches_edit.php6
-rw-r--r--pkg_config.10.xml2
-rw-r--r--pkg_config.8.xml2
-rw-r--r--pkg_config.8.xml.amd642
5 files changed, 9 insertions, 5 deletions
diff --git a/config/systempatches/system_patches.php b/config/systempatches/system_patches.php
index 7fe860bd..793448d7 100644
--- a/config/systempatches/system_patches.php
+++ b/config/systempatches/system_patches.php
@@ -67,7 +67,7 @@ if ($_GET['act'] == "del") {
}
if (($_GET['act'] == "fetch") && ($a_patches[$_GET['id']])) {
- $savemsg = patch_fetch(& $a_patches[$_GET['id']]) ? gettext("Patch Fetched Successfully") : gettext("Patch Fetch Failed");
+ $savemsg = patch_fetch($a_patches[$_GET['id']]) ? gettext("Patch Fetched Successfully") : gettext("Patch Fetch Failed");
}
if (($_GET['act'] == "test") && ($a_patches[$_GET['id']])) {
$savemsg = patch_test_apply($a_patches[$_GET['id']]) ? gettext("Patch can be applied cleanly") : gettext("Patch can NOT be applied cleanly");
diff --git a/config/systempatches/system_patches_edit.php b/config/systempatches/system_patches_edit.php
index ffa2fe13..39d0f12a 100644
--- a/config/systempatches/system_patches_edit.php
+++ b/config/systempatches/system_patches_edit.php
@@ -86,7 +86,11 @@ if ($_POST) {
$reqdfieldsn = array(gettext("Description"),gettext("URL/Commit ID"));
}
- do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
+ $pf_version=substr(trim(file_get_contents("/etc/version")),0,3);
+ if ($pf_version < 2.1)
+ do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors);
+ else
+ do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors);
if (!empty($_POST['location']) && !is_commit_id($_POST['location']) && !is_URL($_POST['location'])) {
$input_errors[] = gettext("The supplied commit ID/URL appears to be invalid.");
diff --git a/pkg_config.10.xml b/pkg_config.10.xml
index d4653457..0ebf61fd 100644
--- a/pkg_config.10.xml
+++ b/pkg_config.10.xml
@@ -1315,7 +1315,7 @@
<name>System Patches</name>
<descr>A package to apply and maintain custom system patches.</descr>
<maintainer>jimp@pfsense.org</maintainer>
- <version>1.0</version>
+ <version>1.0.1</version>
<category>System</category>
<status>RELEASE</status>
<config_file>https://packages.pfsense.org/packages/config/systempatches/systempatches.xml</config_file>
diff --git a/pkg_config.8.xml b/pkg_config.8.xml
index 61da5344..e45331a9 100644
--- a/pkg_config.8.xml
+++ b/pkg_config.8.xml
@@ -1742,7 +1742,7 @@
<name>System Patches</name>
<descr>A package to apply and maintain custom system patches.</descr>
<maintainer>jimp@pfsense.org</maintainer>
- <version>1.0</version>
+ <version>1.0.1</version>
<category>System</category>
<status>RELEASE</status>
<config_file>https://packages.pfsense.org/packages/config/systempatches/systempatches.xml</config_file>
diff --git a/pkg_config.8.xml.amd64 b/pkg_config.8.xml.amd64
index 40e35b3a..77e11384 100644
--- a/pkg_config.8.xml.amd64
+++ b/pkg_config.8.xml.amd64
@@ -1729,7 +1729,7 @@
<name>System Patches</name>
<descr>A package to apply and maintain custom system patches.</descr>
<maintainer>jimp@pfsense.org</maintainer>
- <version>1.0</version>
+ <version>1.0.1</version>
<category>System</category>
<status>RELEASE</status>
<config_file>https://packages.pfsense.org/packages/config/systempatches/systempatches.xml</config_file>