From 21773b37109f57c8fe488af6262365b23e9d0da1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Thu, 5 May 2022 23:27:21 +0800 Subject: [PATCH] fix warns --- server.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server.c b/server.c index 5bdbc6f..4ba9d01 100644 --- a/server.c +++ b/server.c @@ -294,6 +294,7 @@ static int s2_set(thread_timer_t *timer) { break; } pthread_cleanup_pop(0); + return r; } static int s3_set_data(thread_timer_t *timer) { @@ -475,7 +476,7 @@ static void handle_accept(void *p) { pthread_cleanup_push((void*)&kill_timer, thread); int accept_fd = timer_pointer_of(p)->accept_fd; uint32_t index = timer_pointer_of(p)->index; - char *buff = timer_pointer_of(p)->buf; + uint8_t *buff = timer_pointer_of(p)->buf; CMDPACKET* cp = (CMDPACKET*)buff; ssize_t numbytes = 0, offset = 0; while(