diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2007-02-05 04:49:02 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2007-02-05 04:49:02 +0000 |
commit | 9fa3a8a1921b89f2abdc562132ee264bab258585 (patch) | |
tree | e5f03fcffac6473613febfee55c1323c43489fba /packages | |
parent | f53ff408d1aa32e3d6ff16750587fc81efc2a849 (diff) | |
download | pfsense-packages-9fa3a8a1921b89f2abdc562132ee264bab258585.tar.gz pfsense-packages-9fa3a8a1921b89f2abdc562132ee264bab258585.tar.bz2 pfsense-packages-9fa3a8a1921b89f2abdc562132ee264bab258585.zip |
Use correct locking. Mount rw ro for embedded (not that its supported)
Diffstat (limited to 'packages')
-rw-r--r-- | packages/bandwidthd/bandwidthd.inc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/packages/bandwidthd/bandwidthd.inc b/packages/bandwidthd/bandwidthd.inc index a36159cf..42fe39a4 100644 --- a/packages/bandwidthd/bandwidthd.inc +++ b/packages/bandwidthd/bandwidthd.inc @@ -29,15 +29,22 @@ */ function bandwidthd_install_deinstall() { + conf_mount_rw(); + config_lock(); exec("cd /var/db/pkg/ && pkg_delete `ls | grep bandwidthd`"); exec("rm /usr/local/etc/rc.d/bandwidthd*"); exec("rm -rf /usr/local/bandwidthd*"); exec("rm /usr/local/www/bandwidthd"); + conf_mount_ro(); + config_unlock(); } function bandwidthd_install_config() { global $config, $g; + conf_mount_rw(); + config_lock(); + /* user defined values */ $meta_refresh = $config['installedpackages']['bandwidthd']['config'][0]['metarefresh']; if($meta_refresh) @@ -173,6 +180,9 @@ EOF; exec("echo \"Please start bandwidthd to populate this directory.\" > /usr/local/bandwidthd/htdocs/index.html"); + conf_mount_ro(); + config_unlock(); + start_service("bandwidthd"); } |