if (q == -ENXIO)
continue;
if (q < 0) {
- log_error_errno(-r, "Failed to query %s: %m", path_table[i]);
+ log_error_errno(r, "Failed to query %s: %m", path_table[i]);
r = q;
continue;
}
_cleanup_free_ char *p = NULL;
r = sd_path_home(i, arg_suffix, &p);
- if (r < 0) {
- log_error_errno(-r, "Failed to query %s: %m", n);
- return r;
- }
+ if (r < 0)
+ return log_error_errno(r, "Failed to query %s: %m", n);
printf("%s\n", p);
return 0;