summaryrefslogtreecommitdiff
path: root/cmd_fusemount.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2022-12-19 16:05:54 -0500
committerKent Overstreet <kent.overstreet@linux.dev>2022-12-19 16:05:54 -0500
commit1eae1d718c228fb1fc3e7a47a830a2c71f84b5cf (patch)
treeda47d7b5b6591ca45951eb63bdee21a313ce8aec /cmd_fusemount.c
parente2670a38d1ad6038d64687cb1d585349508e06d7 (diff)
Use bch2_err_str() instead of strerror()
This correctly prints out our private error codes. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'cmd_fusemount.c')
-rw-r--r--cmd_fusemount.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd_fusemount.c b/cmd_fusemount.c
index 216094f0..4470f838 100644
--- a/cmd_fusemount.c
+++ b/cmd_fusemount.c
@@ -17,6 +17,7 @@
#include "libbcachefs/btree_iter.h"
#include "libbcachefs/buckets.h"
#include "libbcachefs/dirent.h"
+#include "libbcachefs/errcode.h"
#include "libbcachefs/error.h"
#include "libbcachefs/fs-common.h"
#include "libbcachefs/inode.h"
@@ -1229,7 +1230,7 @@ int cmd_fusemount(int argc, char *argv[])
c = bch2_fs_open(ctx.devices, ctx.nr_devices, bch_opts);
if (IS_ERR(c))
die("error opening %s: %s", ctx.devices_str,
- strerror(-PTR_ERR(c)));
+ bch2_err_str(PTR_ERR(c)));
/* Fuse */
struct fuse_session *se =