diff options
author | David Wood <david@wood2.org.uk> | 2015-12-31 13:46:50 +0000 |
---|---|---|
committer | David Wood <david@wood2.org.uk> | 2015-12-31 13:46:50 +0000 |
commit | 60e15be211c5de855ab3d9746c78eb7296c50cde (patch) | |
tree | 862af8eaa4a8ba95af792b3c98c484e33f2bc2ca /src/etc/inc/config.inc | |
parent | 2e4cad90499f968474c4eca0852f352f1526b617 (diff) | |
parent | 8dccfb20643cfda6b55429177410e6c66fcf0bbd (diff) | |
download | pfsense-60e15be211c5de855ab3d9746c78eb7296c50cde.zip pfsense-60e15be211c5de855ab3d9746c78eb7296c50cde.tar.gz |
Merge remote-tracking branch 'upstream/master' into rfc4638, fix conflict with c399d0d
Diffstat (limited to 'src/etc/inc/config.inc')
-rw-r--r-- | src/etc/inc/config.inc | 27 |
1 files changed, 18 insertions, 9 deletions
diff --git a/src/etc/inc/config.inc b/src/etc/inc/config.inc index 4792ac3..5f038fa 100644 --- a/src/etc/inc/config.inc +++ b/src/etc/inc/config.inc @@ -36,10 +36,6 @@ CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - - pfSense_BUILDER_BINARIES: /sbin/mount /sbin/umount /sbin/halt /sbin/fsck - pfSense_MODULE: config */ if (!function_exists('platform_booting')) { @@ -191,9 +187,6 @@ if (platform_booting(true)) { } } - /* write device name to a file for rc.firmware */ - file_put_contents("{$g['varetc_path']}/cfdevice", $cfgdevice . "\n"); - /* write out an fstab */ $fstab = "/dev/{$cfgpartition} {$g['cf_path']} {$cfgfstype} ro,noatime 1 1\n"; @@ -210,12 +203,28 @@ if (platform_booting(true)) { $config = parse_config(); /* set timezone */ -$timezone = $config['system']['timezone']; -if (!$timezone) { +if (isset($config['system']['timezone']) && + !empty($config['system']['timezone'])) { + $timezone = $config['system']['timezone']; +} elseif (isset($g['default_timezone']) && !empty($g['default_timezone'])) { + $timezone = $g['default_timezone']; +} else { $timezone = "Etc/UTC"; } date_default_timezone_set("$timezone"); +/* Set the default interface language */ +if ($config['system']['language'] <> "") { + $g['language'] = $config['system']['language']; +} elseif ($g['language'] == "") { + $g['language'] = 'en_US'; +} + +if (!function_exists('set_language')) { + require_once("pfsense-utils.inc"); +} +set_language($g['language']); + if ($config_parsed == true) { /* process packager manager custom rules */ if (is_dir("/usr/local/pkg/parse_config")) { |