dccp_senc.c: Kill E_DCCP_WRITE.
authorAndre Noll <maan@systemlinux.org>
Fri, 1 Feb 2008 22:40:24 +0000 (23:40 +0100)
committerAndre Noll <maan@systemlinux.org>
Fri, 1 Feb 2008 22:40:24 +0000 (23:40 +0100)
Use ERRNO_TO_PARA_ERROR() instead.

dccp_send.c
error.h

index a4a9371..5449a6a 100644 (file)
@@ -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 dd5cc57..9ef8195 100644 (file)
--- 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 \