Its almost impossible to figure out a binary patch to a PNG because the content is internally gzipped iirc. (if you do, you'll probably end up with a patch that just replaces the entire contents of the file)
Its unclear whether this overwrites the specified bytes or truncates? Like, what happens if the new content is smaller than the old content? (And I might be revealing my ignorance of the content-range: bytes= header by asking this, but how does this format indicate the size of the file should be truncated?
The example might be better either:
Using a bitmap instead of a PNG - because then the byte ranges at least make a bit of sense, and the file size will stay constant
Or don't use patches in this example, and simply re-send the content with each change
And we can write a second example which uses patches
In section 5.1 it has this example:
This is a weird use case:
content-range: bytes=
header by asking this, but how does this format indicate the size of the file should be truncated?The example might be better either: