X-Git-Url: http://www.dolda2000.com/gitweb/?p=ashd.git;a=blobdiff_plain;f=lib%2Freq.c;h=8ff26e06b6b8aedcae50f61068d3f1c4efa00d9f;hp=662df0f6cddd63ebb0ecfc01fe9e641a379961bb;hb=d9f67feaea01146d7ea10abfff2dc59ff8946ced;hpb=615f3ba3b9ced7a23e5c7c48ad1ff446ff733358 diff --git a/lib/req.c b/lib/req.c index 662df0f..8ff26e0 100644 --- a/lib/req.c +++ b/lib/req.c @@ -290,7 +290,7 @@ int writeresp(FILE *out, struct hthead *resp) return(0); } -int sendreq(int sock, struct hthead *req, int fd) +int sendreq2(int sock, struct hthead *req, int fd, int flags) { int ret, i; struct charbuf buf; @@ -305,7 +305,7 @@ int sendreq(int sock, struct hthead *req, int fd) bufcatstr2(buf, req->headers[i][1]); } bufcatstr2(buf, ""); - ret = sendfd(sock, fd, buf.b, buf.d); + ret = sendfd2(sock, fd, buf.b, buf.d, flags); buffree(buf); if(ret < 0) return(-1); @@ -313,6 +313,11 @@ int sendreq(int sock, struct hthead *req, int fd) return(0); } +int sendreq(int sock, struct hthead *req, int fd) +{ + return(sendreq2(sock, req, fd, MSG_NOSIGNAL | MSG_DONTWAIT)); +} + int recvreq(int sock, struct hthead **reqp) { int fd;