For one of my project, I must use chunked encoding (unknown stream size). One of the client asks for a range "0-" in its GET request to obtain the stream.
Currently, libupnp fails to serve that request and answers with a HTTP_REQUEST_RANGE_NOT_SATISFIABLE and looking at the code, it is clear in CreateHTTPRangeResponseHeader that range AND chunked are not authorized (FileSize < 0) together. But in process_request of webserver.c there is an if (RespInstr->IsRangeActive && RespInstr->IsChunkActive), which seems to indicate that this is a valid case.
I've tried to read RFC and google a bit what is supposed to be done about this case of chunked + range and it seems to be accepted that either the range request can be ignored, or (better) it shall be answered by a "content-range: bytes=xxx-*/*" or similar (and I don't know if this shall be */* or just *)
I've done 2 patches, one to ignore, the other one to build such "content-range", but I'm pretty green on that domain and I don't know what is the proper option.
Any suggestion ?