mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
Fixed syntax error in esp_http_server.rst
Merges: https://github.com/espressif/esp-idf/pull/5021
This commit is contained in:
parent
4a005a02f9
commit
9759aa4ad2
@ -35,7 +35,7 @@ Application Example
|
||||
* as well be any binary data (needs type casting).
|
||||
* In case of string data, null termination will be absent, and
|
||||
* content length would give length of string */
|
||||
char[100] content;
|
||||
char content[100];
|
||||
|
||||
/* Truncate if content length larger than the buffer */
|
||||
size_t recv_size = MIN(req->content_len, sizeof(content));
|
||||
|
@ -33,7 +33,7 @@ HTTP Server 组件提供了在 ESP32 上运行轻量级 Web 服务器的功能
|
||||
/* 定义 HTTP POST 请求数据的目标缓存区
|
||||
* httpd_req_recv() 只接收 char* 数据,但也可以是任意二进制数据(需要类型转换)
|
||||
* 对于字符串数据,null 终止符会被省略,content_len 会给出字符串的长度 */
|
||||
char[100] content;
|
||||
char content[100];
|
||||
|
||||
/* 如果内容长度大于缓冲区则截断 */
|
||||
size_t recv_size = MIN(req->content_len, sizeof(content));
|
||||
|
Loading…
Reference in New Issue
Block a user