ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/trunk/src/packet.c
(Generate patch)

Comparing ircd-hybrid/trunk/src/packet.c (file contents):
Revision 2880 by michael, Sun Mar 31 17:09:50 2013 UTC vs.
Revision 2881 by michael, Mon Jan 20 17:15:39 2014 UTC

# Line 294 | Line 294 | read_packet(fde_t *fd, void *data)
294        /* translate openssl error codes, sigh */
295        if (length < 0)
296          switch (SSL_get_error(fd->ssl, length))
297 <        {
297 >        {
298            case SSL_ERROR_WANT_WRITE:
299 <            fd->flags.pending_read = 1;
300 <            SetSendqBlocked(client_p);
301 <            comm_setselect(fd, COMM_SELECT_WRITE, (PF *) sendq_unblocked,
302 <                           client_p, 0);
303 <            return;
304 <          case SSL_ERROR_WANT_READ:
305 <            errno = EWOULDBLOCK;
299 >            comm_setselect(fd, COMM_SELECT_WRITE, (PF *)sendq_unblocked, client_p, 0);
300 >            return;
301 >          case SSL_ERROR_WANT_READ:
302 >              errno = EWOULDBLOCK;
303            case SSL_ERROR_SYSCALL:
304 <            break;
304 >              break;
305            case SSL_ERROR_SSL:
306              if (errno == EAGAIN)
307                break;
308            default:
309 <            length = errno = 0;
310 <        }
309 >            length = errno = 0;
310 >        }
311      }
312      else
313   #endif

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)