chiark / gitweb /
log: add an "error" parameter to all low-level logging calls and intrdouce log_error_...
[elogind.git] / src / test / test-hostname.c
index ad4f2856190878cc120b10b276e37ba61abd8dd0..1bc4126590b529938f2eb8f21a62495e2f39cb5c 100644 (file)
@@ -32,7 +32,7 @@ int main(int argc, char* argv[]) {
 
         r = hostname_setup();
         if (r < 0)
-                fprintf(stderr, "hostname: %s\n", strerror(-r));
+                log_error_errno(-r, "hostname: %m");
 
         return 0;
 }