summaryrefslogtreecommitdiffstats
path: root/etc/inc/voucher.inc
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2012-12-18 09:48:02 +0000
committerErmal <eri@pfsense.org>2012-12-18 09:48:02 +0000
commitc65c3a5d54d060578dc785a8d83c170693836210 (patch)
tree4406df38474ce26f3d413a66dd9ff464b97361b7 /etc/inc/voucher.inc
parenta19ea4786ba93db064be8ce64dbc387b63455762 (diff)
downloadpfsense-c65c3a5d54d060578dc785a8d83c170693836210.zip
pfsense-c65c3a5d54d060578dc785a8d83c170693836210.tar.gz
If there is no roll do not try to save anything
Diffstat (limited to 'etc/inc/voucher.inc')
-rw-r--r--etc/inc/voucher.inc3
1 files changed, 3 insertions, 0 deletions
diff --git a/etc/inc/voucher.inc b/etc/inc/voucher.inc
index 094b829..3356a1a 100644
--- a/etc/inc/voucher.inc
+++ b/etc/inc/voucher.inc
@@ -670,6 +670,9 @@ function voucher_save_db_to_config_zone() {
if (!isset($config['voucher'][$cpzone]['enable']))
return; // no vouchers or don't want to save DB's
+ if (!is_array($config['voucher'][$cpzone]['roll']))
+ return;
+
$voucherlck = lock("voucher{$cpzone}", LOCK_EX);
// walk all active rolls and save runtime DB's to flash
OpenPOWER on IntegriCloud