From 855ee618a66c38579e7445dfc124dc7f00595041 Mon Sep 17 00:00:00 2001 From: Ryo Nakamura Date: Sat, 11 Mar 2023 22:11:44 +0900 Subject: add note to mscp_cleanup() and mscp_free() mscp_join() must be called before mscp_cleanup() and mscp_free() are called. Need fix. --- include/mscp.h | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'include') diff --git a/include/mscp.h b/include/mscp.h index 92a59ae..c210881 100644 --- a/include/mscp.h +++ b/include/mscp.h @@ -208,16 +208,21 @@ int mscp_join(struct mscp *m); void mscp_get_stats(struct mscp *m, struct mscp_stats *s); /** - * @brief Cleanup the mscp instance. Before calling mscp_cleanup(), must - * call mscp_join(). After mscp_cleanup() called, the mscp instance - * can restart from mscp_connect(). + * @brief Cleanup the mscp instance. Before calling mscp_cleanup(), + * must call mscp_join(). After mscp_cleanup() called, the mscp + * instance can restart from mscp_connect(). Note that do not call + * mscp_cleanup() before callign mscp_join(). It causes crash (ToDo: + * check status of copy threads and return error when they are + * running). * * @param m mscp instance. */ void mscp_cleanup(struct mscp *m); /** - * @brief Release the mscp instance. + * @brief Release the mscp instance. Note that do not call * + mscp_free() before calling mscp_join(). It causes crash (ToDo: check + * status of copy threads and return error when they are running). * * @param m mscp instance. */ -- cgit v1.2.3