From 30f065a97b74fcd3a731470faf4e385e62ab4775 Mon Sep 17 00:00:00 2001 From: Jakob Hasse Date: Sun, 23 Apr 2023 10:39:21 +0800 Subject: [PATCH] doc: fixed pthread_create call in example --- docs/en/api-reference/system/esp_pthread.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/en/api-reference/system/esp_pthread.rst b/docs/en/api-reference/system/esp_pthread.rst index 1a2042db82..a763358dbe 100644 --- a/docs/en/api-reference/system/esp_pthread.rst +++ b/docs/en/api-reference/system/esp_pthread.rst @@ -30,7 +30,7 @@ Example to tune the stack size of the pthread: cfg.stack_size = (4 * 1024); esp_pthread_set_cfg(&cfg); - pthread_create(&t1, NULL, thread_func); + pthread_create(&t1, NULL, thread_func, NULL); } The API can also be used for inheriting the settings across threads. For example: @@ -49,7 +49,7 @@ The API can also be used for inheriting the settings across threads. For example { printf("In my_thread1\n"); pthread_t t2; - pthread_create(&t2, NULL, my_thread2); + pthread_create(&t2, NULL, my_thread2, NULL); return NULL; } @@ -63,7 +63,7 @@ The API can also be used for inheriting the settings across threads. For example cfg.inherit_cfg = true; esp_pthread_set_cfg(&cfg); - pthread_create(&t1, NULL, my_thread1); + pthread_create(&t1, NULL, my_thread1, NULL); } API Reference