treewide: no need to negate errno for log_*_errno()
It corrrectly handles both positive and negative errno values.
This commit is contained in:
@@ -290,7 +290,7 @@ static void do_journal_append(char *file) {
|
||||
}
|
||||
n = loop_read(f, p + 10, BOOTCHART_MAX, false);
|
||||
if (n < 0) {
|
||||
log_error_errno(-n, "Failed to read bootchart data: %m");
|
||||
log_error_errno(n, "Failed to read bootchart data: %m");
|
||||
close(f);
|
||||
return;
|
||||
}
|
||||
@@ -302,7 +302,7 @@ static void do_journal_append(char *file) {
|
||||
|
||||
r = sd_journal_sendv(iovec, j);
|
||||
if (r < 0)
|
||||
log_error_errno(-r, "Failed to send bootchart: %m");
|
||||
log_error_errno(r, "Failed to send bootchart: %m");
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
|
||||
Reference in New Issue
Block a user