Skip to content

Commit

Permalink
Merge pull request #42 from mkbloke/stream-raw
Browse files Browse the repository at this point in the history
Fix "isn't numeric" error in range request header parsing
  • Loading branch information
stuarta committed Mar 9, 2022
2 parents c3cd36c + 286ecda commit c4abbb0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/stream/stream_raw.pl
Expand Up @@ -120,7 +120,7 @@
if ($ENV{'HTTP_RANGE'}) {
# Figure out the size of the requested chunk
($start, $end) = $ENV{'HTTP_RANGE'} =~ /bytes\W+(\d*)-(\d*)\W*$/;
if ($end < 1 || $end > $size) {
if ($end eq '' || $end < 1 || $end > $size) {
$end = $size;
}
$size = $end - $start+1;
Expand Down

0 comments on commit c4abbb0

Please sign in to comment.