diff -uNr ircservices-5.0.52/Changes ircservices-5.0.53/Changes --- ircservices-5.0.52/Changes 2005-05-12 12:03:27 +0900 +++ ircservices-5.0.53/Changes 2005-05-12 23:33:08 +0900 @@ -1,5 +1,6 @@ Version 5.0 ----------- +2005/05/12 .53 Fixed bug causing server connection to fail. 2005/05/12 .52 Fixed occasional corruption of the NickServ REGISTER syntax string upon reconfiguration (OperServ REHASH). Reported by diff -uNr ircservices-5.0.52/send.c ircservices-5.0.53/send.c --- ircservices-5.0.52/send.c 2005-05-12 12:19:45 +0900 +++ ircservices-5.0.53/send.c 2005-05-12 23:36:56 +0900 @@ -144,12 +144,12 @@ return; vsnprintf(buf, sizeof(buf), fmt, args); if (source) { - if (sock_isconn(servsock)) + if (servsock) sockprintf(servsock, ":%s %s\r\n", source, buf); if (debug) log("debug: Sent: :%s %s", source, buf); } else { - if (sock_isconn(servsock)) + if (servsock) sockprintf(servsock, "%s\r\n", buf); if (debug) log("debug: Sent: %s", buf); diff -uNr ircservices-5.0.52/sockets.c ircservices-5.0.53/sockets.c --- ircservices-5.0.52/sockets.c 2005-05-12 12:19:45 +0900 +++ ircservices-5.0.53/sockets.c 2005-05-12 23:36:57 +0900 @@ -1160,6 +1160,8 @@ errno = EBADF; return -1; } + if (!sock_isconn(s)) /* not yet connected */ + return 0; if (s->wend != s->wptr) { if (s->wptr > s->wend) /* wrapped around? */ maxwrite = s->wtop - s->wptr; diff -uNr ircservices-5.0.52/version.sh ircservices-5.0.53/version.sh --- ircservices-5.0.52/version.sh 2005-05-12 12:04:01 +0900 +++ ircservices-5.0.53/version.sh 2005-05-12 23:33:21 +0900 @@ -6,7 +6,7 @@ # $PROGRAM is the string returned as the first part of a /VERSION reply, # and must not contain spaces. It is not used anywhere else. PROGRAM=ircservices -VERSION=5.0.52 +VERSION=5.0.53 # Increment Services build number if [ -f version.c ] ; then