summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorErmal Luçi <eri@pfsense.org>2009-07-01 18:02:20 +0000
committerErmal Luçi <eri@pfsense.org>2009-07-01 18:02:20 +0000
commit24e3d98679e16396efe864aa6b15d3d981ec9a47 (patch)
tree12308e78b3c8f1dbae1fca6c05ed3abadc6193e7 /etc
parent328f902e567995e130b64063801c453ac05b248f (diff)
downloadpfsense-24e3d98679e16396efe864aa6b15d3d981ec9a47.zip
pfsense-24e3d98679e16396efe864aa6b15d3d981ec9a47.tar.gz
Prevent recursive calls to conf_mount_*
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/config.inc8
1 files changed, 7 insertions, 1 deletions
diff --git a/etc/inc/config.inc b/etc/inc/config.inc
index 7b80d15..9fc50f4 100644
--- a/etc/inc/config.inc
+++ b/etc/inc/config.inc
@@ -442,6 +442,9 @@ function conf_mount_rw() {
if($g['platform'] == "cdrom" or $g['platform'] == "pfSense")
return;
+ if (is_subsystem_dirty('mount'))
+ return;
+
$status = mwexec("/sbin/mount -u -w {$g['cf_path']}");
if($status <> 0) {
if($g['booting'])
@@ -463,6 +466,8 @@ function conf_mount_rw() {
$status = mwexec("/sbin/mount -u -w /");
}
}
+
+ mark_subsystem_dirty('mount');
}
/****f* config/conf_mount_ro
@@ -489,6 +494,7 @@ function conf_mount_ro() {
if($g['platform'] == "cdrom" or $g['platform'] == "pfSense")
return;
+ clear_subsystem_dirty('mount');
/* sync data, then force a remount of /cf */
mwexec("/bin/sync");
mwexec("/bin/sync");
@@ -1298,4 +1304,4 @@ function set_device_perms() {
if($g['booting']) echo ".";
$config = parse_config();
-?> \ No newline at end of file
+?>
OpenPOWER on IntegriCloud