Commit fca5c9e3 fca5c9e3f62ade28bffcef684c78d0bbff869667 by Sergey Poznyakoff

Bugfix

* libmailutils/sockaddr/fromnode.c [!MAILUTILS_IPV6] Handle
AF_UNSPEC same way as AF_INET.
Do not bail out if service is not given, assume port = 0 instead.
* mailutils/base/version.c (mu_conf_option): Reflect IPv6 support.
1 parent adca074d
...@@ -37,6 +37,9 @@ static struct mu_conf_option mu_conf_option[] = { ...@@ -37,6 +37,9 @@ static struct mu_conf_option mu_conf_option[] = {
37 { "MAILSPOOLDIR=" MU_PATH_MAILDIR, N_("Default mail spool directory") }, 37 { "MAILSPOOLDIR=" MU_PATH_MAILDIR, N_("Default mail spool directory") },
38 { "SCHEME=" MU_DEFAULT_SCHEME, N_("Default mailbox type") }, 38 { "SCHEME=" MU_DEFAULT_SCHEME, N_("Default mailbox type") },
39 { "LOG_FACILITY=" LOG_FACILITY_STRING, N_("Default syslog facility") }, 39 { "LOG_FACILITY=" LOG_FACILITY_STRING, N_("Default syslog facility") },
40 #ifdef MAILUTILS_IPV6
41 { "IPV6", N_("IPv6 support") },
42 #endif
40 #ifdef USE_LIBPAM 43 #ifdef USE_LIBPAM
41 { "USE_LIBPAM", N_("PAM support") }, 44 { "USE_LIBPAM", N_("PAM support") },
42 #endif 45 #endif
......
...@@ -162,7 +162,7 @@ mu_sockaddr_from_node (struct mu_sockaddr **retval, const char *node, ...@@ -162,7 +162,7 @@ mu_sockaddr_from_node (struct mu_sockaddr **retval, const char *node,
162 freeaddrinfo (res); 162 freeaddrinfo (res);
163 } 163 }
164 #else 164 #else
165 if (mh->family == AF_INET) 165 if (mh->family == AF_INET || mh->family == AF_UNSPEC)
166 { 166 {
167 short port; 167 short port;
168 struct hostent *hp; 168 struct hostent *hp;
...@@ -200,7 +200,7 @@ mu_sockaddr_from_node (struct mu_sockaddr **retval, const char *node, ...@@ -200,7 +200,7 @@ mu_sockaddr_from_node (struct mu_sockaddr **retval, const char *node,
200 else if (mh->port) 200 else if (mh->port)
201 port = htons (mh->port); 201 port = htons (mh->port);
202 else 202 else
203 return MU_ERR_NONAME; 203 port = 0;
204 204
205 if (!node) 205 if (!node)
206 { 206 {
......