diff --git a/resourceschedule/ffrt/c/loop.h b/resourceschedule/ffrt/c/loop.h index 35d76cedbb1d024918331dc83aa3de0870326839..62aee092a2ed82ac39602a85a35163f2a99bbeaf 100644 --- a/resourceschedule/ffrt/c/loop.h +++ b/resourceschedule/ffrt/c/loop.h @@ -88,6 +88,8 @@ FFRT_C_API void ffrt_loop_stop(ffrt_loop_t loop); /** * @brief Controls an epoll file descriptor on ffrt loop. * + * @warning Do not call `exit` in `cb` - this my cause unexpected behavior. + * * @param loop Indicates a loop handle. * @param op Indicates operation on the target file descriptor. * @param fd Indicates the target file descriptor on which to perform the operation. @@ -103,6 +105,7 @@ FFRT_C_API int ffrt_loop_epoll_ctl(ffrt_loop_t loop, int op, int fd, uint32_t ev /** * @brief Starts a timer on ffrt loop. * + * @warning Do not call `exit` in `cb` - this my cause unexpected behavior. * @param loop Indicates a loop handle. * @param timeout Indicates the number of milliseconds that specifies timeout. * @param data Indicates user data used in cb. diff --git a/resourceschedule/ffrt/c/queue.h b/resourceschedule/ffrt/c/queue.h index cd82aa80c5b6ac6d22e0437a67fcc7ffbe23f7fb..86b80252eb004468347986394bed719493248cff 100644 --- a/resourceschedule/ffrt/c/queue.h +++ b/resourceschedule/ffrt/c/queue.h @@ -118,6 +118,7 @@ FFRT_C_API uint64_t ffrt_queue_attr_get_timeout(const ffrt_queue_attr_t* attr); /** * @brief Sets the timeout callback function of a serial queue attribute. * + * @warning Do not call `exit` in `f` - this my cause unexpected behavior. * @param attr Serial queue attribute pointer. * @param f Serial queue timeout callback function. * @since 10 diff --git a/resourceschedule/ffrt/c/timer.h b/resourceschedule/ffrt/c/timer.h index 1f13a4dffe037407146f584764fd982215607b36..ddc7301216f563f77d33724d67f7abd9e3aa53ae 100644 --- a/resourceschedule/ffrt/c/timer.h +++ b/resourceschedule/ffrt/c/timer.h @@ -42,6 +42,8 @@ /** * @brief Starts a timer on ffrt worker * + * @warning Do not call `exit` in `cb` - this my cause unexpected behavior. + * * @param qos Indicates qos of the worker that runs timer. * @param timeout Indicates the number of milliseconds that specifies timeout. * @param data Indicates user data used in cb.