summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/inc/system.inc9
1 files changed, 4 insertions, 5 deletions
diff --git a/etc/inc/system.inc b/etc/inc/system.inc
index dcc8df6..97096c4 100644
--- a/etc/inc/system.inc
+++ b/etc/inc/system.inc
@@ -52,10 +52,9 @@ function activate_powerd() {
function get_default_sysctl_value($id) {
global $sysctls;
- foreach($sysctls as $sysctl => $value) {
- if($sysctl == $id)
- return $value;
- }
+
+ if (isset($sysctls[$id]))
+ return $value;
}
function activate_sysctls() {
@@ -1480,4 +1479,4 @@ function system_get_dmesg_boot() {
return file_get_contents("{$g['varlog_path']}/dmesg.boot");
}
-?> \ No newline at end of file
+?>
OpenPOWER on IntegriCloud