]> git.ipfire.org Git - thirdparty/systemd.git/commit
log: add underflow assert guard
authorLuca Boccassi <luca.boccassi@gmail.com>
Fri, 17 Oct 2025 10:27:55 +0000 (11:27 +0100)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 17 Oct 2025 16:11:49 +0000 (01:11 +0900)
commitb62c681b117e77b3ef56331ba8c92b5eaf0d2b0d
tree7c24239bdaa3e32fb016f4b26fa8c181195aee5b
parente9fd2bbfffc5c2c7cd1ea0a288d5435fc15e387f
log: add underflow assert guard

We often use ssize_t in log_error macros, but typically return int
which confuses coverity, as technically there is no guarantee that
int and ssize_t have the same range. Add an assert to enforce it.
src/basic/log.h