summaryrefslogtreecommitdiffstats
path: root/lib/libzfs/libzfs_diff.c
diff options
context:
space:
mode:
authorнаб <[email protected]>2021-06-05 01:04:37 +0200
committerBrian Behlendorf <[email protected]>2021-06-09 13:05:34 -0700
commitb05ae1a82ab686f037806dbd932eb3cd5ce34c00 (patch)
tree162c0c30d26d8094598877080ee4644d2e76977c /lib/libzfs/libzfs_diff.c
parentb12a6d961cd5631d92123cf483512c48354063f9 (diff)
libzfs: write_inuse_diffs_one: format strerror() with "%s"
Fixes 50353dbd ("Let zfs diff be more permissive") which accidentally introduced a build warning. Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Tony Nguyen <[email protected]> Signed-off-by: Ahelenia Ziemiańska <[email protected]> Closes #12197
Diffstat (limited to 'lib/libzfs/libzfs_diff.c')
-rw-r--r--lib/libzfs/libzfs_diff.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libzfs/libzfs_diff.c b/lib/libzfs/libzfs_diff.c
index bb17806b1..79268cb4b 100644
--- a/lib/libzfs/libzfs_diff.c
+++ b/lib/libzfs/libzfs_diff.c
@@ -262,7 +262,7 @@ write_inuse_diffs_one(FILE *fp, differ_info_t *di, uint64_t dobj)
fobjerr = get_stats_for_obj(di, di->fromsnap, dobj, fobjname,
MAXPATHLEN, &fsb);
if (fobjerr && di->zerr != ENOTSUP && di->zerr != ENOENT) {
- zfs_error_aux(di->zhp->zfs_hdl, strerror(di->zerr));
+ zfs_error_aux(di->zhp->zfs_hdl, "%s", strerror(di->zerr));
zfs_error(di->zhp->zfs_hdl, di->zerr, di->errbuf);
/*
* Let's not print an error for the same object more than
@@ -276,7 +276,8 @@ write_inuse_diffs_one(FILE *fp, differ_info_t *di, uint64_t dobj)
if (tobjerr && di->zerr != ENOTSUP && di->zerr != ENOENT) {
if (!already_logged) {
- zfs_error_aux(di->zhp->zfs_hdl, strerror(di->zerr));
+ zfs_error_aux(di->zhp->zfs_hdl,
+ "%s", strerror(di->zerr));
zfs_error(di->zhp->zfs_hdl, di->zerr, di->errbuf);
}
}