dev-setup: normalize logging around lock_dev_console()

Previously this function would log loudly in some cases but not in
others. Clean this up, and dont log at all, matching our coding style
which says we should either log in all error cases or in none.

Both callers of this function do logging already, hence no need to
duplicate it here.
This commit is contained in:
Lennart Poettering
2024-02-09 14:19:16 +01:00
parent 317cb6f9b5
commit a0f6b68135
+1 -1
View File
@@ -28,7 +28,7 @@ int lock_dev_console(void) {
r = lock_generic(fd, LOCK_BSD, LOCK_EX);
if (r < 0)
return log_error_errno(r, "Failed to lock /dev/console: %m");
return r;
return TAKE_FD(fd);
}