mirror of
https://codeberg.org/dnkl/yambar.git
synced 2025-04-20 03:35:41 +02:00
module/battery: regression: allow poll-interval == 0
The regression was introduced after 1.9.0, hence no changelog entry.
This commit is contained in:
parent
6220a07aaf
commit
f948b9f8f9
1 changed files with 3 additions and 1 deletions
|
@ -586,7 +586,9 @@ conf_verify_poll_interval(keychain_t *chain, const struct yml_node *node)
|
||||||
if (!conf_verify_unsigned(chain, node))
|
if (!conf_verify_unsigned(chain, node))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if (yml_value_as_int(node) < min_poll_interval) {
|
const long value = yml_value_as_int(node);
|
||||||
|
|
||||||
|
if (value != 0 && value < min_poll_interval) {
|
||||||
LOG_ERR("%s: interval value cannot be less than %ldms",
|
LOG_ERR("%s: interval value cannot be less than %ldms",
|
||||||
conf_err_prefix(chain, node), min_poll_interval);
|
conf_err_prefix(chain, node), min_poll_interval);
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Add table
Reference in a new issue