Quanah Gibson-Mount:
> --On Wednesday, October 31, 2012 9:02 AM -0400 Wietse Venema
> <[email protected]> wrote:
>
> > This patch breaks "postfix start", i.e. the master terminates
> > with an error. I'll investigate this as electric power permits.
It depends on main.cf configuration. Below is the corrected version.
Wietse
*** ./src/util/myaddrinfo.c- Tue Feb 1 15:04:28 2011
--- ./src/util/myaddrinfo.c Mon Oct 29 15:42:36 2012
***************
*** 78,83 ****
--- 78,84 ----
/* into printable form. The result buffers should be large
/* enough to hold the printable address or port including the
/* null terminator.
+ /* This function strips off the IPv6 datalink suffix.
/*
/* sockaddr_to_hostname() converts a binary network address
/* into a hostname or service. The result buffer should be
***************
*** 202,207 ****
--- 203,209 ----
#include <msg.h>
#include <inet_proto.h>
#include <myaddrinfo.h>
+ #include <split_at.h>
/* Application-specific. */
***************
*** 607,622 ****
}
return (0);
#else
/*
* Native getnameinfo(3) version.
*/
! return (getnameinfo(sa, salen,
! hostaddr ? hostaddr->buf : (char *) 0,
! hostaddr ? sizeof(hostaddr->buf) : 0,
! portnum ? portnum->buf : (char *) 0,
! portnum ? sizeof(portnum->buf) : 0,
! NI_NUMERICHOST | NI_NUMERICSERV));
#endif
}
--- 609,628 ----
}
return (0);
#else
+ int ret;
/*
* Native getnameinfo(3) version.
*/
! ret = getnameinfo(sa, salen,
! hostaddr ? hostaddr->buf : (char *) 0,
! hostaddr ? sizeof(hostaddr->buf) : 0,
! portnum ? portnum->buf : (char *) 0,
! portnum ? sizeof(portnum->buf) : 0,
! NI_NUMERICHOST | NI_NUMERICSERV);
! if (hostaddr != 0 && ret == 0 && sa->sa_family == AF_INET6)
! (void) split_at(hostaddr->buf, '%');
! return (ret);
#endif
}
*** ./src/util/Makefile.in- Sun Sep 23 19:28:54 2012
--- ./src/util/Makefile.in Mon Oct 29 15:44:12 2012
***************
*** 1526,1531 ****
--- 1526,1532 ----
myaddrinfo.o: myaddrinfo.h
myaddrinfo.o: mymalloc.h
myaddrinfo.o: sock_addr.h
+ myaddrinfo.o: split_at.h
myaddrinfo.o: stringops.h
myaddrinfo.o: sys_defs.h
myaddrinfo.o: valid_hostname.h