Commits

ianb  committed 9d9fc04

Allowed for a -1 value in the range

  • Participants
  • Parent commits 82de5df

Comments (0)

Files changed (1)

File paste/httpheaders.py

     """
     def compose(self, first_byte=None, last_byte=None, total_length=None):
         retval = "%d-%d/%d" % (first_byte, last_byte, total_length)
-        assert first_byte <= last_byte
+        assert last_byte == -1 or first_byte <= last_byte
         assert last_byte  < total_length
         return (retval,)
 _ContentRange('Content-Range', 'entity', 'RFC 2616, 14.6')