mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
jack: fix signed and unsigned compares
This commit is contained in:
parent
4cb36762b0
commit
a4593a0d96
2 changed files with 6 additions and 6 deletions
|
|
@ -30,14 +30,14 @@
|
|||
|
||||
jack_ringbuffer_t *jack_ringbuffer_create(size_t sz)
|
||||
{
|
||||
int power_of_two;
|
||||
size_t power_of_two;
|
||||
jack_ringbuffer_t *rb;
|
||||
|
||||
rb = calloc(1, sizeof(jack_ringbuffer_t));
|
||||
if (rb == NULL)
|
||||
return NULL;
|
||||
|
||||
for (power_of_two = 1; 1 << power_of_two < sz; power_of_two++);
|
||||
for (power_of_two = 1; 1u << power_of_two < sz; power_of_two++);
|
||||
|
||||
rb->size = 1 << power_of_two;
|
||||
rb->size_mask = rb->size - 1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue