From 31938a8560a664c32a9d72f1fc2d4347b232e6e9 Mon Sep 17 00:00:00 2001 From: Michal Schmidt Date: Fri, 28 Nov 2014 13:17:02 +0100 Subject: core: convert log_unit_*() to log_unit_*_errno() Using: find . -name '*.[ch]' | xargs sed -r -i -e \ 's/log_unit_(debug|info|notice|warning|error|emergency)\(([^"]+), "(.*)%s"(.*), strerror\(-([a-zA-Z_]+)\)\);/log_unit_\1_errno(\2, \5, "\3%m"\4);/' --- src/sysv-generator/sysv-generator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/sysv-generator/sysv-generator.c') diff --git a/src/sysv-generator/sysv-generator.c b/src/sysv-generator/sysv-generator.c index 4328469909..5ff621d1fa 100644 --- a/src/sysv-generator/sysv-generator.c +++ b/src/sysv-generator/sysv-generator.c @@ -193,7 +193,7 @@ static int generate_unit_file(SysvStub *s) { STRV_FOREACH(p, s->wanted_by) { r = add_symlink(s->name, *p); if (r < 0) - log_unit_error(s->name, "Failed to create 'Wants' symlink to %s: %s", *p, strerror(-r)); + log_unit_error_errno(s->name, r, "Failed to create 'Wants' symlink to %s: %m", *p); } return 0; -- cgit v1.2.3