workarounds i utf8 check
[postfix-cn.git] / newaliases-gecos
index 5c8f63f..31139c2 100755 (executable)
@@ -14,14 +14,14 @@ grep -q "hash:$gecos" /etc/postfix/main.cf || exit 0
 # Load CARNET Tools
 . /usr/share/carnet-tools/functions.sh
 
-getent passwd | awk -F: '
+awk -F: '
         $3 >= 100 && $1 != "nobody" && $5 \
         {
                 split($5, g, ",");
                if (g[1]=="") {next};
                 gsub(/ /, ".", g[1]);
                 print tolower(g[1]) ": " $1;
-        }' > $gecos.dpkg-tmp.$$
+        }' < /etc/passwd > $gecos.dpkg-tmp.$$
 
 
 if ! cmp -s $gecos.dpkg-tmp.$$ $gecos > /dev/null; then