]> git.lizzy.rs Git - plan9front.git/commitdiff
rc-httpd: append carriage return to content-length header
authorAlex Musolino <alex@musolino.id.au>
Tue, 7 Jan 2020 06:58:59 +0000 (17:28 +1030)
committerAlex Musolino <alex@musolino.id.au>
Tue, 7 Jan 2020 06:58:59 +0000 (17:28 +1030)
rc/bin/rc-httpd/handlers/serve-static

index db935d48e77d84dbea8a1ce868aedc3b4550fbbb..119665ee35102e38696b329fd19ca6555b813bd8 100755 (executable)
@@ -39,7 +39,7 @@ max_age=3600  # 1 hour
 echo 'HTTP/1.1 200 OK'^$cr
 emit_extra_headers
 echo 'Content-type: '^$type^$cr
-echo 'Content-length: '^`{ls -l $full_path | awk '{print $6}'}
+echo 'Content-length: '^`{ls -l $full_path | awk '{print $6}'}^$cr
 echo 'Cache-control: max-age='^$max_age^$cr
 echo $cr
 exec cat $full_path