summaryrefslogtreecommitdiffstats
path: root/etc/inc
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2014-11-11 21:35:29 +0100
committerErmal <eri@pfsense.org>2014-11-11 21:35:29 +0100
commitbaca968c298f978321796836e9ef8a2a76f579ab (patch)
tree3d1dc1b7a03586ab07280c40775bbd298d0430ca /etc/inc
parente16f6d03a790e0f8b4f8abaf770ae00c32381b57 (diff)
downloadpfsense-baca968c298f978321796836e9ef8a2a76f579ab.zip
pfsense-baca968c298f978321796836e9ef8a2a76f579ab.tar.gz
Do not do operations for empty group members
Diffstat (limited to 'etc/inc')
-rw-r--r--etc/inc/auth.inc5
1 files changed, 4 insertions, 1 deletions
diff --git a/etc/inc/auth.inc b/etc/inc/auth.inc
index 0fe9d20..81a54bd 100644
--- a/etc/inc/auth.inc
+++ b/etc/inc/auth.inc
@@ -623,10 +623,13 @@ function local_group_set($group, $reset = false) {
$group_name = $group['name'];
$group_gid = $group['gid'];
- $group_members = "''";
+ $group_members = '';
if (!$reset && !empty($group['member']) && count($group['member']) > 0)
$group_members = implode(",",$group['member']);
+ if (empty($group_members))
+ return;
+
/* read from group db */
$fd = popen("/usr/sbin/pw groupshow {$group_name} 2>&1", "r");
$pwread = fgets($fd);
OpenPOWER on IntegriCloud