httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jor...@apache.org
Subject svn commit: r231030 - /httpd/httpd/trunk/modules/http/byterange_filter.c
Date Tue, 09 Aug 2005 13:16:49 GMT
Author: jorton
Date: Tue Aug  9 06:16:46 2005
New Revision: 231030

URL: http://svn.apache.org/viewcvs?rev=231030&view=rev
Log:
* modules/http/byterange_filter.c (ap_byterange_filter): Update some
comments.

Modified:
    httpd/httpd/trunk/modules/http/byterange_filter.c

Modified: httpd/httpd/trunk/modules/http/byterange_filter.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/http/byterange_filter.c?rev=231030&r1=231029&r2=231030&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/http/byterange_filter.c (original)
+++ httpd/httpd/trunk/modules/http/byterange_filter.c Tue Aug  9 06:16:46 2005
@@ -215,9 +215,9 @@
             continue;
         }
 
-        /* these calls to apr_brigade_partition() should theoretically
-         * never fail because of the above call to apr_brigade_length(),
-         * but what the heck, we'll check for an error anyway */
+        /* These calls to apr_brigage_partition should only fail in
+         * pathological cases, e.g. a file being truncated whilst
+         * being served. */
         if ((rv = apr_brigade_partition(bb, range_start, &ec)) != APR_SUCCESS) {
             ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r,
                           PARTITION_ERR_FMT, range_start, clength);
@@ -260,12 +260,10 @@
             apr_size_t len;
 
             if (apr_bucket_copy(ec, &foo) != APR_SUCCESS) {
-                /* this shouldn't ever happen due to the call to
-                 * apr_brigade_length() above which normalizes
-                 * indeterminate-length buckets.  just to be sure,
-                 * though, this takes care of uncopyable buckets that
-                 * do somehow manage to slip through.
-                 */
+                /* As above; this should not fail since the bucket has
+                 * a known length, but just to be sure, this takes
+                 * care of uncopyable buckets that do somehow manage
+                 * to slip through.  */
                 /* XXX: check for failure? */
                 apr_bucket_read(ec, &str, &len, APR_BLOCK_READ);
                 apr_bucket_copy(ec, &foo);



Mime
View raw message