Date: Tue, 29 Sep 2009 19:10:04 GMT From: dfilter@FreeBSD.ORG (dfilter service) To: freebsd-bugs@FreeBSD.org Subject: Re: misc/139214: commit references a PR Message-ID: <200909291910.n8TJA4hf086113@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR misc/139214; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: misc/139214: commit references a PR Date: Tue, 29 Sep 2009 19:09:32 +0000 (UTC) Author: mav Date: Tue Sep 29 19:09:17 2009 New Revision: 197621 URL: http://svn.freebsd.org/changeset/base/197621 Log: Fix bug, when RADIUS client gave up after single sendto() error, do not trying backup servers. PR: kern/103764, misc/139214 Modified: head/lib/libradius/radlib.c Modified: head/lib/libradius/radlib.c ============================================================================== --- head/lib/libradius/radlib.c Tue Sep 29 18:44:34 2009 (r197620) +++ head/lib/libradius/radlib.c Tue Sep 29 19:09:17 2009 (r197621) @@ -650,17 +650,12 @@ rad_continue_send_request(struct rad_han n = sendto(h->fd, h->out, h->out_len, 0, (const struct sockaddr *)&h->servers[h->srv].addr, sizeof h->servers[h->srv].addr); - if (n != h->out_len) { - if (n == -1) - generr(h, "sendto: %s", strerror(errno)); - else - generr(h, "sendto: short write"); - return -1; - } - + if (n != h->out_len) + tv->tv_sec = 1; /* Do not wait full timeout if send failed. */ + else + tv->tv_sec = h->servers[h->srv].timeout; h->try++; h->servers[h->srv].num_tries++; - tv->tv_sec = h->servers[h->srv].timeout; tv->tv_usec = 0; *fd = h->fd; _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200909291910.n8TJA4hf086113>