summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2013-09-17 15:12:23 -0400
committerjim-p <jimp@pfsense.org>2013-09-17 15:13:32 -0400
commit819a603c2deb2c842d0132459731d1ba79498d4c (patch)
tree5571ee906a87e10ef4bb28c6bffcceb0da40e8f8 /etc
parent2e9d9ede6beaf79dc9942efe0d26d49a9ba144c7 (diff)
downloadpfsense-819a603c2deb2c842d0132459731d1ba79498d4c.zip
pfsense-819a603c2deb2c842d0132459731d1ba79498d4c.tar.gz
Switch to rw mode before file operations on RFC2136 cache. Fixes #3201
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/services.inc3
1 files changed, 3 insertions, 0 deletions
diff --git a/etc/inc/services.inc b/etc/inc/services.inc
index 84da081..6939676 100644
--- a/etc/inc/services.inc
+++ b/etc/inc/services.inc
@@ -2046,6 +2046,8 @@ EOD;
// 25 Days
$maxCacheAgeSecs = 25 * 24 * 60 * 60;
$need_update = false;
+
+ conf_mount_rw();
/* Update IPv4 if we have it. */
if (is_ipaddrv4($wanip)) {
if (($wanip != $cachedipv4) || (($currentTime - $cacheTimev4) > $maxCacheAgeSecs) || $forced) {
@@ -2078,6 +2080,7 @@ EOD;
}
} else
@unlink("{$cacheFile}.ipv6");
+ conf_mount_ro();
$upinst .= "\n"; /* mind that trailing newline! */
OpenPOWER on IntegriCloud