dgaudet 97/09/25 20:26:26
Modified: src CHANGES
src/main http_protocol.c
Log:
send_fb would not detect aborted connections in some situations
Reviewed by: Jim Jagielski, Roy Fielding
Revision Changes Path
1.450 +4 -1 apachen/src/CHANGES
Index: CHANGES
===================================================================
RCS file: /export/home/cvs/apachen/src/CHANGES,v
retrieving revision 1.449
retrieving revision 1.450
diff -u -r1.449 -r1.450
--- CHANGES 1997/09/26 03:22:59 1.449
+++ CHANGES 1997/09/26 03:26:21 1.450
@@ -1,5 +1,8 @@
Changes with Apache 1.3b1
-
+
+ *) send_fb would not detect aborted connections in some situations.
+ [Dean Gaudet]
+
*) mod_include would use uninitialized data when parsing certain
expressions involving && and ||. [Brian Slesinsky] PR#1139
1.163 +4 -2 apachen/src/main/http_protocol.c
Index: http_protocol.c
===================================================================
RCS file: /export/home/cvs/apachen/src/main/http_protocol.c,v
retrieving revision 1.162
retrieving revision 1.163
diff -u -r1.162 -r1.163
--- http_protocol.c 1997/09/14 10:04:58 1.162
+++ http_protocol.c 1997/09/26 03:26:24 1.163
@@ -1805,6 +1805,7 @@
soft_timeout("send body", r);
+ FD_ZERO(&fds);
while (!r->connection->aborted) {
if ((length > 0) && (total_bytes_sent + IOBUFSIZE) > length)
len = length - total_bytes_sent;
@@ -1813,13 +1814,14 @@
do {
n = bread(fb, buf, len);
- if (n >= 0)
+ if (n >= 0 || r->connection->aborted)
break;
if (n < 0 && errno != EAGAIN)
break;
/* we need to block, so flush the output first */
bflush(r->connection->client);
- FD_ZERO(&fds);
+ if (r->connection->aborted)
+ break;
FD_SET(fd, &fds);
/*
* we don't care what select says, we might as well loop back