explicit cast for fast_mblock_alloc_object

use_iouring
YuQing 2024-11-21 10:21:07 +08:00
parent 13e213e3f8
commit ed65725833
2 changed files with 2 additions and 2 deletions

View File

@ -100,7 +100,7 @@ static inline struct common_blocked_node *common_blocked_queue_alloc_node(
struct common_blocked_node *node;
pthread_mutex_lock(&(queue->lc_pair.lock));
node = fast_mblock_alloc_object(&queue->mblock);
node = (struct common_blocked_node *)fast_mblock_alloc_object(&queue->mblock);
pthread_mutex_unlock(&(queue->lc_pair.lock));
return node;
}

View File

@ -205,7 +205,7 @@ void free_queue_destroy(struct fast_task_queue *queue);
static inline struct fast_task_info *free_queue_pop(
struct fast_task_queue *queue)
{
return fast_mblock_alloc_object(&queue->allocator);
return (struct fast_task_info *)fast_mblock_alloc_object(&queue->allocator);
}
void free_queue_push(struct fast_task_info *task);