mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-15 10:29:47 +00:00
Fix #1462 - add helper function for getting HTTP response status code.
This commit is contained in:
1 parent
1adf7f6b2b
commit
da72dafbfb
5 files changed
+21
No files matched your search
@@ -766,6 +766,17 @@ struct mg_connection *c = mg_http_connect(&mgr, "http://google.com", fn, NULL);
|
||||
if (c == NULL) fatal_error("Cannot create connection");
|
||||
```
|
||||
|
||||
### mg\_http\_status()
|
||||
|
||||
```c
|
||||
int mg_http_status(const struct mg_http_message *hm);
|
||||
```
|
||||
|
||||
Get status code of the HTTP response.
|
||||
Parameters:
|
||||
- `hm` - Parsed HTTP response
|
||||
|
||||
Return value: status code, e.g. `200` for success.
|
||||
|
||||
### mg\_http\_get\_request\_len()
|
||||
|
||||
|
||||
Reference in new issue
Block a user