diff options
Diffstat (limited to 'src/binfmt')
-rw-r--r-- | src/binfmt/binfmt.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/binfmt/binfmt.c b/src/binfmt/binfmt.c index f6b72e0bae..29530bb691 100644 --- a/src/binfmt/binfmt.c +++ b/src/binfmt/binfmt.c @@ -65,11 +65,12 @@ static int apply_rule(const char *rule) { static int apply_file(const char *path, bool ignore_enoent) { _cleanup_fclose_ FILE *f = NULL; + _cleanup_free_ char *pp = NULL; int r; assert(path); - r = search_and_fopen(path, "re", NULL, (const char**) CONF_PATHS_STRV("binfmt.d"), &f); + r = search_and_fopen(path, "re", NULL, (const char**) CONF_PATHS_STRV("binfmt.d"), &f, &pp); if (r < 0) { if (ignore_enoent && r == -ENOENT) return 0; @@ -77,7 +78,7 @@ static int apply_file(const char *path, bool ignore_enoent) { return log_error_errno(r, "Failed to open file '%s': %m", path); } - log_debug("apply: %s", path); + log_debug("apply: %s", pp); for (;;) { _cleanup_free_ char *line = NULL; char *p; @@ -85,7 +86,7 @@ static int apply_file(const char *path, bool ignore_enoent) { k = read_line(f, LONG_LINE_MAX, &line); if (k < 0) - return log_error_errno(k, "Failed to read file '%s': %m", path); + return log_error_errno(k, "Failed to read file '%s': %m", pp); if (k == 0) break; |