/*
- * Copyright (C) 2006-2009 Andre Noll <maan@systemlinux.org>
+ * Copyright (C) 2006-2010 Andre Noll <maan@systemlinux.org>
*
* Licensed under the GPL v2. For licencing details see COPYING.
*/
*/
static bool dccp_recv_ccid_support_check(struct dccp_recv_args_info *conf)
{
- uint8_t ccids[DCCP_MAX_HOST_CCIDS];
- uint8_t nccids = sizeof(ccids), i, j;
+ uint8_t *ccids;
+ int i, j, nccids;
- if (dccp_available_ccids(ccids, &nccids) == NULL)
+ nccids = dccp_available_ccids(&ccids);
+ if (nccids <= 0)
return false;
for (i = 0; i < conf->ccid_given; i++) {
if (iovcnt == 0)
goto err;
ret = para_readv(pdd->fd, iov, iovcnt);
+ /* EAGAIN is possible even if FD_ISSET */
+ if (ret < 0 && is_errno(-ret, EAGAIN))
+ return;
if (ret == 0)
ret = -E_RECV_EOF;
if (ret < 0)