diff options
author | Not Zed <NotZed@Ximian.com> | 2004-12-01 11:52:11 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2004-12-01 11:52:11 +0800 |
commit | ae4b9b15b54ca28bbb3707a24204277e91a4b9ee (patch) | |
tree | f375742936c7824c0c007f98c8f00e7b91bedbd2 /camel/providers | |
parent | 7f793b912853b340fd2e3d12c26d0452f55227c5 (diff) | |
download | gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.tar gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.tar.gz gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.tar.bz2 gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.tar.lz gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.tar.xz gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.tar.zst gsoc2013-evolution-ae4b9b15b54ca28bbb3707a24204277e91a4b9ee.zip |
** See bug #69615.
2004-11-23 Not Zed <NotZed@Ximian.com>
** See bug #69615.
* camel-smime-context.c (sm_get_passwd): removed. All callers
that passed it now pass NULL. This is so we don't override the
password function set by e-cert-db. Seems to work ok, I think.
2004-11-22 Not Zed <NotZed@Ximian.com>
** See bug #69109.
* providers/smtp/camel-smtp-transport.c (smtp_helo): if we have
ipv6 address and it is numeric, prefix it with "IPv6:"
svn path=/trunk/; revision=28025
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/smtp/camel-smtp-transport.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/camel/providers/smtp/camel-smtp-transport.c b/camel/providers/smtp/camel-smtp-transport.c index 0e1a175d6a..542f8c6b72 100644 --- a/camel/providers/smtp/camel-smtp-transport.c +++ b/camel/providers/smtp/camel-smtp-transport.c @@ -867,8 +867,7 @@ smtp_helo (CamelSmtpTransport *transport, CamelException *ex) { /* say hello to the server */ char *name = NULL, *cmdbuf = NULL, *respbuf = NULL; - const char *token; - int numeric = FALSE; + const char *token, *numeric = NULL; /* these are flags that we set, so unset them in case we are being called a second time (ie, after a STARTTLS) */ @@ -888,13 +887,20 @@ smtp_helo (CamelSmtpTransport *transport, CamelException *ex) if (camel_getnameinfo(transport->localaddr, transport->localaddrlen, &name, NULL, NI_NAMEREQD, NULL) != 0) { if (camel_getnameinfo(transport->localaddr, transport->localaddrlen, &name, NULL, NI_NUMERICHOST, NULL) != 0) name = g_strdup("localhost.localdomain"); - else - numeric = TRUE; + else { + if (transport->localaddr->sa_family == AF_INET6) + numeric = "IPv6:"; + else + numeric = ""; + } } /* hiya server! how are you today? */ token = (transport->flags & CAMEL_SMTP_TRANSPORT_IS_ESMTP) ? "EHLO" : "HELO"; - cmdbuf = g_strdup_printf(numeric ? "%s [%s]\r\n" : "%s %s\r\n", token, name); + if (numeric) + cmdbuf = g_strdup_printf("%s [%s%s]\r\n", token, numeric, name); + else + cmdbuf = g_strdup_printf("%s %s\r\n", token, name); g_free (name); d(fprintf (stderr, "sending : %s", cmdbuf)); |