Skip to content
Browse files

Merge pull request #393 from simleb/master

Fix #292 allow space character in password
  • Loading branch information...
2 parents 1d5cc20 + 3587692 commit 800f2697560310fb0e6cb93f814bbac289d07b86 @tomas tomas committed Nov 27, 2013
Showing with 6 additions and 3 deletions.
  1. +6 −3 core/push
View
9 core/push
@@ -67,10 +67,13 @@ send_via_email(){
echo -e "${EMAIL_NOTICE}${EMAIL_HEADER}$(urldecode "$trace_list")${EMAIL_FOOTER}" > "$trace_file.msg"
# only add user/pass if set
- [ -n "$smtp_username" ] && local auth="username=$smtp_username password=$decrypted_pass"
- response=$(mailsender -f "$mail_from" -t "$mail_to" -u "$complete_subject" -s $smtp_server -a $file_list -o message-file="$trace_file.msg" tls=auto $auth)
+ if [ -n "$smtp_username" ]; then
+ response=$(mailsender -f "$mail_from" -t "$mail_to" -u "$complete_subject" -s $smtp_server -a $file_list -o message-file="$trace_file.msg" tls=auto username="$smtp_username" password="$decrypted_pass")
+ else
+ response=$(mailsender -f "$mail_from" -t "$mail_to" -u "$complete_subject" -s $smtp_server -a $file_list -o message-file="$trace_file.msg" tls=auto)
+ fi
- if [ -n $(find_in "$response" 'ERROR') ]; then
+ if [ -n "$(find_in "$response" 'ERROR')" ]; then
log "$STRING_ERROR_EMAIL"
log "\n This is the complete error message: \n $response\n"
else

0 comments on commit 800f269

Please sign in to comment.
Something went wrong with that request. Please try again.