module-pipe-tunnel: avoid bitfield data race

Move the have_sync bitfield away from the other bitfields because they
are written from different threads and might cause a data race.

Fixes #3706
This commit is contained in:
Wim Taymans 2023-12-13 12:48:51 +01:00
parent c07bef13be
commit bbb3b5d8b1

View file

@ -187,7 +187,6 @@ struct impl {
unsigned int do_disconnect:1; unsigned int do_disconnect:1;
unsigned int driving:1; unsigned int driving:1;
unsigned int have_sync:1;
unsigned int may_pause:1; unsigned int may_pause:1;
unsigned int paused:1; unsigned int paused:1;
@ -203,6 +202,7 @@ struct impl {
float corr; float corr;
uint64_t next_time; uint64_t next_time;
unsigned int have_sync:1;
}; };
static uint64_t get_time_ns(struct impl *impl) static uint64_t get_time_ns(struct impl *impl)