netjack2: limit period_size to quantum_limit

To avoid large periods that might not fit in the quantum.
This commit is contained in:
Wim Taymans 2026-05-05 19:06:31 +02:00
parent aa29fefbd2
commit ca46444d13

View file

@ -850,6 +850,7 @@ static int handle_follower_setup(struct impl *impl, struct nj2_session_params *p
peer->params.recv_midi_channels < 0 ||
peer->params.sample_rate == 0 ||
peer->params.period_size == 0 ||
peer->params.period_size > impl->quantum_limit ||
peer->params.mtu == 0 ||
peer->params.mtu > MAX_MTU ||
!encoding_supported(peer->params.sample_encoder)) {