summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbruno <bruno.stein@bluepex.com>2016-08-23 08:50:39 -0300
committerRenato Botelho <garga@FreeBSD.org>2016-09-13 09:52:04 -0300
commitced8b00e0191dbefdda3350277fe70736f5c0bcb (patch)
tree09f2f3f54d332a2d29b86a5ea9fa30e8c8f9c010
parent72d3b35d7522b2cd81c8b9bc68fe8ad59167e9e0 (diff)
downloadFreeBSD-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.inc5
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']) {
OpenPOWER on IntegriCloud