gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnurl] 252/264: smtp: set auth correctly


From: gnunet
Subject: [gnurl] 252/264: smtp: set auth correctly
Date: Thu, 30 Apr 2020 16:09:15 +0200

This is an automated email from the git hooks/post-receive script.

nikita pushed a commit to branch master
in repository gnurl.

commit 446fb0518bd4525c679343dd88d75d13dd201be3
Author: Daniel Stenberg <address@hidden>
AuthorDate: Sat Apr 25 00:22:21 2020 +0200

    smtp: set auth correctly
    
    Regression since 7.69.0 and 68fb25fa3fcff.
    
    The code wrongly assigned 'from' instead of 'auth' which probably was a
    copy and paste mistake from other code, leading to that auth could
    remain NULL and later cause an error to be returned.
    
    Assisted-by: Eric Sauvageau
    Fixes #5294
    Closes #5295
---
 lib/smtp.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/lib/smtp.c b/lib/smtp.c
index 93e004d20..bf65f246f 100644
--- a/lib/smtp.c
+++ b/lib/smtp.c
@@ -625,8 +625,7 @@ static CURLcode smtp_perform_mail(struct connectdata *conn)
         utf8 = TRUE;
 
       if(host.name) {
-        free(from);
-        from = aprintf("<%s@%s>", address, host.name);
+        auth = aprintf("<%s@%s>", address, host.name);
 
         Curl_free_idnconverted_hostname(&host);
       }
@@ -636,8 +635,6 @@ static CURLcode smtp_perform_mail(struct connectdata *conn)
         auth = aprintf("<%s>", address);
 
       free(address);
-      if(!from)
-        return CURLE_OUT_OF_MEMORY;
     }
     else
       /* Empty AUTH, RFC-2554, sect. 5 */

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]