]> git.kaiwu.me - haproxy.git/commit
[BUILD] fix build on Solaris due to recent log changes
authorWilly Tarreau <w@1wt.eu>
Wed, 5 Dec 2007 23:53:51 +0000 (00:53 +0100)
committerWilly Tarreau <w@1wt.eu>
Wed, 5 Dec 2007 23:53:51 +0000 (00:53 +0100)
commit127f966f4bda0379e60d0f8ac031b3480139f71a
tree633b0f50e2f2b9b1aaca960608f5cc6ea71c447c
parent019767b546dcbe6225feb5894caa227c0649f98c
[BUILD] fix build on Solaris due to recent log changes

Solaris, as well as many other unixes doesn't know about sun_len
for UNIX domain sockets. It does not honnor the __SOCKADDR_COMMON
macro either. After looking at MacOS-X man (which is the same as
BSD man), OpenBSD man, and examples on the net, it appears that
those which support sun_len do not actually use it, or at least
ignore it as long as it's zero. Since all the sockaddr structures
are zeroed prior to being filled, it causes no problem not to set
sun_len, and this fixes build on other platforms.

Another problem on Solaris was that the "sun" name is already
defined as a macro returning a number, so it was necessary to
rename it.
src/log.c
src/standard.c