From dd1b211faeaeb00efb937c5fa584b10d06ca6687 Mon Sep 17 00:00:00 2001 From: Jilles Tjoelker Date: Sat, 21 Jun 2008 02:29:21 +0200 Subject: [PATCH] ident: use rb_read/rb_write instead of direct syscalls --- src/s_auth.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/s_auth.c b/src/s_auth.c index 927c0d1de..83407b37b 100644 --- a/src/s_auth.c +++ b/src/s_auth.c @@ -539,7 +539,7 @@ auth_connect_callback(rb_fde_t *F, int error, void *data) rb_snprintf(authbuf, sizeof(authbuf), "%u , %u\r\n", auth->rport, auth->lport); - if(write(rb_get_fd(auth->F), authbuf, strlen(authbuf)) == -1) + if(rb_write(auth->F, authbuf, strlen(authbuf)) != strlen(authbuf)) { auth_error(auth); return; @@ -568,7 +568,7 @@ read_auth_reply(rb_fde_t *F, void *data) int count; char buf[AUTH_BUFSIZ + 1]; /* buffer to read auth reply into */ - len = read(rb_get_fd(F), buf, AUTH_BUFSIZ); + len = rb_read(F, buf, AUTH_BUFSIZ); if(len < 0 && rb_ignore_errno(errno)) {