You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2020/03/27 17:12:37 UTC

[Bug 54962] Apache will set incorrect Content-Length header and may serve partial files

https://bz.apache.org/bugzilla/show_bug.cgi?id=54962

Ståle Kristoffersen <st...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |staalebk@gmail.com

--- Comment #1 from Ståle Kristoffersen <st...@gmail.com> ---
Created attachment 37131
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=37131&action=edit
small program to provoke the error

This program, compiled with gcc -o loop test.c will generate random length
files.
The file "/usr/local/apache2/htdocs/test.txt" will be swapped out atomically,
and will always be consistent on disk with the end of the file be the line "End
of file!\n".

When fetching this through the latest Apache (compiled from
httpd-2.4.41.tar.gz, apr-1.7.0.tar.gz and apr-util-1.6.1.tar.gz) it sometimes
works as expected, sometimes I get a partial file (but the last line is then
always "Lorem ipsum d", which is the same length as "End of line!\n").

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org