diff options
author | Alexander Wilke <nachtfalkeaw@web.de> | 2012-06-25 21:08:35 +0300 |
---|---|---|
committer | Alexander Wilke <nachtfalkeaw@web.de> | 2012-06-25 21:08:35 +0300 |
commit | fcecf3a222ca2c1474f6ae8827263b61414df1d6 (patch) | |
tree | 112c5978435a6e0d5e9296f03619cf72fc30f281 | |
parent | 75e4ad1b3ea46288e35c57729dfc8b0b196e8a1e (diff) | |
download | pfsense-packages-fcecf3a222ca2c1474f6ae8827263b61414df1d6.tar.gz pfsense-packages-fcecf3a222ca2c1474f6ae8827263b61414df1d6.tar.bz2 pfsense-packages-fcecf3a222ca2c1474f6ae8827263b61414df1d6.zip |
freeradius2: check if it needs to be uninstalled the old way or not
-rw-r--r-- | config/freeradius2/freeradius.inc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/config/freeradius2/freeradius.inc b/config/freeradius2/freeradius.inc index 0e31b8d1..7c5cd914 100644 --- a/config/freeradius2/freeradius.inc +++ b/config/freeradius2/freeradius.inc @@ -56,9 +56,11 @@ if (substr(trim(file_get_contents("/etc/version")),0,3) == "2.0") { // End of system check function freeradius_deinstall_command() { - exec("cd /var/db/pkg && pkg_delete `ls | grep freeradius`"); - exec("rm -rf " . RADDB); - exec("rm -rf /var/run/radiusd/"); + if (substr(trim(file_get_contents("/etc/version")),0,3) == "2.0") { + exec("cd /var/db/pkg && pkg_delete `ls | grep freeradius`"); + exec("rm -rf " . RADDB); + exec("rm -rf /var/run/radiusd/"); + } } function freeradius_install_command() { |