diff options
author | jim-p <jim@pingle.org> | 2010-05-01 00:00:44 -0400 |
---|---|---|
committer | jim-p <jim@pingle.org> | 2010-05-01 00:00:44 -0400 |
commit | a9e757fce0e6e8e15dad63a02472959af52f8ff4 (patch) | |
tree | a2a5031680f2020aac77d6efa26f557ca7cfad22 /config/urltables/urltables.inc | |
parent | ef1073fe24628948d40c381d9c9ec56714edba91 (diff) | |
download | pfsense-packages-a9e757fce0e6e8e15dad63a02472959af52f8ff4.tar.gz pfsense-packages-a9e757fce0e6e8e15dad63a02472959af52f8ff4.tar.bz2 pfsense-packages-a9e757fce0e6e8e15dad63a02472959af52f8ff4.zip |
Add URL Table patch package for 1.2.3.
Diffstat (limited to 'config/urltables/urltables.inc')
-rw-r--r-- | config/urltables/urltables.inc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/config/urltables/urltables.inc b/config/urltables/urltables.inc new file mode 100644 index 00000000..a2c372ce --- /dev/null +++ b/config/urltables/urltables.inc @@ -0,0 +1,18 @@ +<?php + +function urltables_install() { + global $g, $config; + + // Test to make sure the patch is not already applied. + $out = `patch -fslC --reverse -p1 -b .before_urltables -d / -i /usr/local/pkg/urltables.patch |& grep -ci reject`; + if ($out == 0) { + // If the patch has not already been applied, test to see if it will apply cleanly. + $out = `patch -fsNlC -p1 -b .before_urltables -d / -i /usr/local/pkg/urltables.patch |& grep -ci reject`; + if ($out == 0) { + // The patch should apply cleanly, let 'er rip. + mwexec("patch -fsNl -p1 -b .before_urltables -d / -i /usr/local/pkg/urltables.patch "); + } + } +} + +?>
\ No newline at end of file |