Skip to content

Commit

Permalink
commented unused us_queue_get_free()
Browse files Browse the repository at this point in the history
  • Loading branch information
mdevaev committed Feb 29, 2024
1 parent 4296d5d commit d9401b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/libs/queue.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ int us_queue_get(us_queue_s *queue, void **item, ldf timeout) {

#undef _WAIT_OR_UNLOCK

int us_queue_get_free(us_queue_s *queue) {
/*int us_queue_get_free(us_queue_s *queue) {
US_MUTEX_LOCK(queue->mutex);
const uint size = queue->size;
US_MUTEX_UNLOCK(queue->mutex);
return queue->capacity - size;
}
}*/
2 changes: 1 addition & 1 deletion src/libs/queue.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@ void us_queue_destroy(us_queue_s *queue);

int us_queue_put(us_queue_s *queue, void *item, ldf timeout);
int us_queue_get(us_queue_s *queue, void **item, ldf timeout);
int us_queue_get_free(us_queue_s *queue);
// int us_queue_get_free(us_queue_s *queue);

0 comments on commit d9401b7

Please sign in to comment.