io-util: add an unlikely decorator for a test that should never hold

This commit is contained in:
Lennart Poettering
2018-02-20 15:39:31 +01:00
parent 8ac2f74fb6
commit 7f7210c210
+1 -1
View File
@@ -137,7 +137,7 @@ int loop_write(int fd, const void *buf, size_t nbytes, bool do_poll) {
assert(fd >= 0);
assert(buf);
if (nbytes > (size_t) SSIZE_MAX)
if (_unlikely_(nbytes > (size_t) SSIZE_MAX))
return -EINVAL;
do {