From d85091bebd5abb6f473a31dd118f4d853d1317c9 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Fri, 1 Feb 2008 23:40:24 +0100 Subject: [PATCH] dccp_senc.c: Kill E_DCCP_WRITE. Use ERRNO_TO_PARA_ERROR() instead. --- dccp_send.c | 8 +++----- error.h | 1 - 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/dccp_send.c b/dccp_send.c index a4a9371a..5449a6a9 100644 --- a/dccp_send.c +++ b/dccp_send.c @@ -51,7 +51,7 @@ struct dccp_client { struct chunk_queue *cq; }; -static void dccp_pre_select( int *max_fileno, fd_set *rfds, +static void dccp_pre_select(int *max_fileno, fd_set *rfds, __a_unused fd_set *wfds) { if (listen_fd < 0) @@ -145,10 +145,8 @@ static int dccp_write(int fd, const char *buf, size_t len) */ if (ret < 0 && errno == EAGAIN) return written; - if (ret < 0) { - PARA_ERROR_LOG("%s\n", strerror(errno)); - return -E_DCCP_WRITE; - } + if (ret < 0) + return -ERRNO_TO_PARA_ERROR(errno); written += ret; } return written; diff --git a/error.h b/error.h index dd5cc579..9ef8195c 100644 --- a/error.h +++ b/error.h @@ -347,7 +347,6 @@ extern const char **para_errlist[]; #define DCCP_SEND_ERRORS \ - PARA_ERROR(DCCP_WRITE, "dccp write error"), \ #define FD_ERRORS \ -- 2.39.5