diff options
author | bruno <bruno.stein@bluepex.com> | 2016-08-23 08:50:39 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2016-09-13 09:52:04 -0300 |
commit | ced8b00e0191dbefdda3350277fe70736f5c0bcb (patch) | |
tree | 09f2f3f54d332a2d29b86a5ea9fa30e8c8f9c010 | |
parent | 72d3b35d7522b2cd81c8b9bc68fe8ad59167e9e0 (diff) | |
download | FreeBSD-ports-ced8b00e0191dbefdda3350277fe70736f5c0bcb.zip FreeBSD-ports-ced8b00e0191dbefdda3350277fe70736f5c0bcb.tar.gz |
get raw config if exists
(cherry picked from commit 24e0f32c0414827f1213a79272bb160413a59b3d)
-rw-r--r-- | net/pfSense-pkg-OpenBGPD/files/usr/local/pkg/openbgpd.inc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/pfSense-pkg-OpenBGPD/files/usr/local/pkg/openbgpd.inc b/net/pfSense-pkg-OpenBGPD/files/usr/local/pkg/openbgpd.inc index 07a2c73..6c4a485 100644 --- a/net/pfSense-pkg-OpenBGPD/files/usr/local/pkg/openbgpd.inc +++ b/net/pfSense-pkg-OpenBGPD/files/usr/local/pkg/openbgpd.inc @@ -57,10 +57,9 @@ function openbgpd_install_conf() { // Since we need to embed this in a string, copy to a var. Can't embed constants. $bgpd_config_base = PKG_BGPD_CONFIG_BASE; - if ($config['installedpackages']['openbgpd']['rawconfig'] && $config['installedpackages']['openbgpd']['rawconfig']['item']) { + if (isset($config['installedpackages']['openbgpd']['rawconfig']) && !empty($config['installedpackages']['openbgpd']['rawconfig'])) { // If there is a raw config specified in the config.xml, use that instead of the assisted config - $conffile = implode("\n", $config['installedpackages']['openbgpd']['rawconfig']['item']); - //$conffile = $config['installedpackages']['openbgpd']['rawconfig']; + $conffile = base64_decode($config['installedpackages']['openbgpd']['rawconfig']); } else { // Generate bgpd.conf based on the assistant if ($config['installedpackages']['openbgpd']['config']) { |