diff options
author | Ermal Luçi <eri@pfsense.org> | 2010-02-11 15:00:52 +0000 |
---|---|---|
committer | Ermal Luçi <eri@pfsense.org> | 2010-02-11 15:00:52 +0000 |
commit | 451ec561a24bd0fc8f718a93584e06ca9281a05c (patch) | |
tree | e56491bbcf70f2e6ca8384d5a8a0c5f1943273ec /etc | |
parent | 01fa26e8b68f75a71c85935698534033fdb24113 (diff) | |
download | pfsense-451ec561a24bd0fc8f718a93584e06ca9281a05c.zip pfsense-451ec561a24bd0fc8f718a93584e06ca9281a05c.tar.gz |
Ticket #351. Prevent wrong config.xml creation.
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/voucher.inc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/etc/inc/voucher.inc b/etc/inc/voucher.inc index b348fc1..1cd4679 100644 --- a/etc/inc/voucher.inc +++ b/etc/inc/voucher.inc @@ -390,12 +390,14 @@ function voucher_save_db_to_config() { $rollent['used'] = base64_encode($bitmask); $active_vouchers = voucher_read_active_db($roll); $db = array(); + $dbi = 1; foreach($active_vouchers as $voucher => $line) { list($timestamp,$minutes) = explode(",", $line); $activent['voucher'] = $voucher; $activent['timestamp'] = $timestamp; $activent['minutes'] = $minutes; - $db[] = $activent; + $db["v{$dbi}"] = $activent; + $dbi++; } $rollent['active'] = $db; } |