Fixed syntax error in esp_http_server.rst

Merges: https://github.com/espressif/esp-idf/pull/5021
This commit is contained in:
morsisko 2020-03-29 15:53:58 +02:00 committed by bot
parent 4a005a02f9
commit 9759aa4ad2
2 changed files with 2 additions and 2 deletions

View file

@ -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));

View file

@ -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));