live-systems.org/gitweb
/
live-debconfig.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9b16015
)
Avoid failing in passwd if gid for a group the user should be added to does not ...
author
Daniel Baumann
<daniel@debian.org>
Fri, 18 Jan 2013 19:34:46 +0000
(20:34 +0100)
committer
Daniel Baumann
<daniel@debian.org>
Fri, 18 Jan 2013 19:34:46 +0000
(20:34 +0100)
scripts/debconfig/0010-passwd
patch
|
blob
|
blame
|
history
diff --git
a/scripts/debconfig/0010-passwd
b/scripts/debconfig/0010-passwd
index
f7eaf60
..
726868e
100755
(executable)
--- a/
scripts/debconfig/0010-passwd
+++ b/
scripts/debconfig/0010-passwd
@@
-375,7
+375,10
@@
then
if [ -n "${_USER_GID}" ]
then
- _USER_OPTIONS="${_USER_OPTIONS} --gid ${_USER_GID}"
+ if getent group "${_USER_GID}" > /dev/null 2>&1
+ then
+ _USER_OPTIONS="${_USER_OPTIONS} --gid ${_USER_GID}"
+ fi
fi
if [ -n "${_USER_DEFAULT_GROUPS}" ]
@@
-470,7
+473,10
@@
do
if [ -n "${_GID}" ]
then
- _OPTIONS="${_OPTIONS} --gid ${_GID}"
+ if getent group "${_GID}" > /dev/null 2>&1
+ then
+ _OPTIONS="${_OPTIONS} --gid ${_GID}"
+ fi
fi
if [ -n "${_DEFAULT_GROUPS}" ]