From: Marko Kreen Date: Wed, 26 Nov 2008 23:09:06 +0000 (+0000) Subject: Quick win32 fixes. X-Git-Tag: pgbouncer_1_3_rc1~35 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f6c2a20e1aa4891e280b38785d548f89130f6b8f;p=pgbouncer Quick win32 fixes. It not only compiles now, but even boots.. --- diff --git a/Makefile b/Makefile index 5aacb6c..84ddfe0 100644 --- a/Makefile +++ b/Makefile @@ -52,7 +52,7 @@ EXT = .exe CPPFLAGS += -I$(srcdir)/win32 WSRCS = win32service.c WOBJS = $(WSRCS:.c=.o) -WHDRS = win32service.h config_win32.h +WHDRS = win32service.h compat_win32.h srcs += $(addprefix $(srcdir)/win32/, $(WSRCS)) hdrs += $(addprefix $(srcdir)/win32/, $(WHDRS)) objs += $(addprefix $(builddir)/lib/, $(WOBJS)) diff --git a/src/loader.c b/src/loader.c index 9f95f24..5c64f0f 100644 --- a/src/loader.c +++ b/src/loader.c @@ -232,7 +232,7 @@ void parse_database(char *name, char *connstr) /* host= */ if (!host) { /* default unix socket dir */ - if (!cf_unix_socket_dir) { + if (!*cf_unix_socket_dir) { log_error("skipping database %s because" " unix socket not configured", name); return; diff --git a/src/main.c b/src/main.c index 293333d..801e19e 100644 --- a/src/main.c +++ b/src/main.c @@ -674,7 +674,7 @@ static void win32_startup(int argc, char *argv[]) exit(0); } - if (!WSAStartup(MAKEWORD(2,0), &wsaData)) + if (WSAStartup(MAKEWORD(2,0), &wsaData)) fatal("Cannot start the network subsystem"); } #endif diff --git a/src/pooler.c b/src/pooler.c index 722ccf8..b4ad8d2 100644 --- a/src/pooler.c +++ b/src/pooler.c @@ -357,7 +357,7 @@ void pooler_setup(void) if (cf_listen_addr && !fd_net) fd_net = create_net_socket(cf_listen_addr, cf_listen_port); - if (cf_unix_socket_dir && !fd_unix) + if (*cf_unix_socket_dir && !fd_unix) fd_unix = create_unix_socket(cf_unix_socket_dir, cf_listen_port); if (!fd_net && !fd_unix)