abduco

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | LICENSE

commit 9e6490da33cf74a043e214a3dc10bf620f3f1725
parent ef3645617753f62bdc5f10b6dca344db8f41bab8
Author: Ross Mohn <rpmohn@waxandwane.org>
Date:   Fri, 26 Sep 2014 21:07:32 +0200

AIX support

Diffstat:
abduco.c | 4++--
config.mk | 3+++
2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/abduco.c b/abduco.c @@ -217,7 +217,7 @@ static void usage() { static int create_socket_dir() { size_t maxlen = sizeof(sockaddr.sun_path); char *dirs[] = { getenv("HOME"), getenv("TMPDIR"), "/tmp" }; - int socketfd = socket(AF_LOCAL, SOCK_STREAM, 0); + int socketfd = socket(AF_UNIX, SOCK_STREAM, 0); if (socketfd == -1) return -1; for (unsigned int i = 0; i < countof(dirs); i++) { @@ -265,7 +265,7 @@ static int create_socket(const char *name) { strncat(sockaddr.sun_path, name, maxlen - strlen(sockaddr.sun_path) - 1); strncat(sockaddr.sun_path, server.host, maxlen - strlen(sockaddr.sun_path) - 1); } - return socket(AF_LOCAL, SOCK_STREAM, 0); + return socket(AF_UNIX, SOCK_STREAM, 0); } static bool create_session(const char *name, char * const argv[]) { diff --git a/config.mk b/config.mk @@ -9,6 +9,9 @@ MANPREFIX = ${PREFIX}/share/man INCS = -I. LIBS = -lc -lutil +# AIX +#LIBS = -lc + # Solaris #LIBS = -lc -lsocket