mirror of https://github.com/jetkvm/kvm.git
Remove unnecessary NULL checks in configure_alsa_device
All callers pass non-NULL pointers for actual_rate_out and actual_frame_size_out.
This commit is contained in:
parent
4cadf38e5a
commit
82562b77c4
|
|
@ -589,11 +589,8 @@ static int configure_alsa_device(snd_pcm_t *handle, const char *device_name, uin
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (actual_rate_out) *actual_rate_out = negotiated_rate;
|
*actual_rate_out = negotiated_rate;
|
||||||
if (actual_frame_size_out) {
|
*actual_frame_size_out = negotiated_rate / 50; // 20ms frames
|
||||||
// Calculate actual frame size based on negotiated rate (20ms frames)
|
|
||||||
*actual_frame_size_out = negotiated_rate / 50;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue