forked from drath/libratbag
ratbagd-profile: cap minimum report rate to 125
Fixes the sanity check part of #1563.
This commit is contained in:
@@ -594,8 +594,11 @@ ratbagd_profile_set_report_rate(sd_bus *bus,
|
||||
return r;
|
||||
|
||||
/* basic sanity check */
|
||||
if (rate > 8000)
|
||||
if (rate < 125) {
|
||||
rate = 125;
|
||||
} else if (rate > 8000) {
|
||||
rate = 8000;
|
||||
}
|
||||
|
||||
r = ratbag_profile_set_report_rate(profile->lib_profile, rate);
|
||||
if (r == 0) {
|
||||
|
||||
Reference in New Issue
Block a user