| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
Added the "fd_util" library, which attempts to use the new thread-safe
Linux system calls pipe2(), accept4() and the options O_CLOEXEC,
SOCK_CLOEXEC. Without these, it falls back to FD_CLOEXEC, which is
not thread safe.
This is particularly important for the "pipe" output plugin (and
others, such as JACK/PulseAudio), because we were heavily leaking file
descriptors to child processes.
|
|
|
|
|
| |
g_set_error() is a printf-like function, and expects a format string.
Using the return value of gai_strerror() is unsafe.
|
|
|
|
|
| |
g_strerror() is more portable, and guarantees that the returned string
is UTF-8 encoded.
|
|
|
|
| |
Moved code from listen_add_address() (listen.c) to socket_util.c.
|
|
|
|
|
|
|
|
| |
This updates the copyright header to all be the same, which is
pretty much an update of where to mail request for a copy of the GPL
and the years of the MPD project. This also puts all committers under
'The Music Player Project' umbrella. These entries should go
individually in the AUTHORS file, for consistancy.
|
|
|
|
|
| |
On some systems, the macro IN6_IS_ADDR_V4MAPPED() is not available.
Don't try to convert IPv6 to their IPV4 equivalents in this case.
|
|
|
|
| |
Windows doesn't have the standard headers sys/socket.h and netdb.h.
|
|
|
|
|
| |
Unpack IPv4 addresses which are packed inside an IPv6 address,
i.e. return "127.0.0.1" rather than "::ffff:127.0.0.1".
|
|
Create the socket_util.c library, the first function is
sockaddr_to_string(): it converts a sockaddr struct to a string
containing the IP address in a human-readable form.
|