When users call `git_http_client_read_body`, it should return 0 at the end of a message. When the `on_message_complete` callback is called, this will set `client->state` to `DONE`. In our read loop, we look for this condition and exit. Without this, when there is no data left except the end of message chunk (`0\r\n`) in the http stream, we would block by reading the three bytes off the stream but not making progress in any `on_body` callbacks. Listening to the `on_message_complete` callback allows us to stop trying to read from the socket when we've read the end of message chunk.
| Name |
Last commit
|
Last update |
|---|---|---|
| .github | Loading commit data... | |
| azure-pipelines | Loading commit data... | |
| cmake/Modules | Loading commit data... | |
| deps | Loading commit data... | |
| docs | Loading commit data... | |
| examples | Loading commit data... | |
| fuzzers | Loading commit data... | |
| include | Loading commit data... | |
| script | Loading commit data... | |
| src | Loading commit data... | |
| tests | Loading commit data... | |
| .HEADER | Loading commit data... | |
| .editorconfig | Loading commit data... | |
| .gitattributes | Loading commit data... | |
| .gitignore | Loading commit data... | |
| .mailmap | Loading commit data... | |
| AUTHORS | Loading commit data... | |
| CMakeLists.txt | Loading commit data... | |
| COPYING | Loading commit data... | |
| README.md | Loading commit data... | |
| SECURITY.md | Loading commit data... | |
| api.docurium | Loading commit data... | |
| azure-pipelines.yml | Loading commit data... | |
| git.git-authors | Loading commit data... | |
| package.json | Loading commit data... |