summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2015-09-14 11:47:35 +0200
committerJonas Smedegaard <dr@jones.dk>2015-09-14 11:47:35 +0200
commita9278c203c978a65a7b07f1df0aec61260627387 (patch)
tree983c1a3a44453b63cd3cf35143bf6eb2afd161d7
parentd8b2e92f0770150af481dde11449bf06718efe05 (diff)
Fix quote $user.
-rwxr-xr-xlocalnotifypwexp4
1 files changed, 2 insertions, 2 deletions
diff --git a/localnotifypwexp b/localnotifypwexp
index a485b12..dc8a096 100755
--- a/localnotifypwexp
+++ b/localnotifypwexp
@@ -103,7 +103,7 @@ for user in $users;
do
IFS=":"
- usershadow=$(getent shadow $user)
+ usershadow=$(getent shadow "$user")
# make an array out of it
usershadow=($usershadow)
@@ -127,7 +127,7 @@ do
then
subject=$(eval "echo \"$usersubjecttemplate\"")
body=$(eval "echo \"$userbodytemplate\"")
- echo -e "$body" | $notifyprog -s "$subject" $user
+ echo -e "$body" | $notifyprog -s "$subject" "$user"
else
if [[ $age -ge $aged ]];
then