diff --git a/src/dwarfs_main.cpp b/src/dwarfs_main.cpp index 505e46d5..40d53a54 100644 --- a/src/dwarfs_main.cpp +++ b/src/dwarfs_main.cpp @@ -912,7 +912,12 @@ void op_getxattr(fuse_req_t req, fuse_ino_t ino, char const* name, size_t size << ", extra_size=" << extra_size; if (value.empty()) { + // Linux and macOS disagree on the error code for "attribute not found" +#ifdef __APPLE__ + return ENOATTR; +#else return ENODATA; +#endif } if (size == 0) { diff --git a/test/tools_test.cpp b/test/tools_test.cpp index 39937a33..bba3c60c 100644 --- a/test/tools_test.cpp +++ b/test/tools_test.cpp @@ -553,10 +553,6 @@ class driver_runner { wait_until_file_ready(mountpoint, std::chrono::seconds(5)); #else std::vector options; -#ifdef __APPLE__ - options.push_back("-o"); - options.push_back("noapplexattr"); -#endif if (!subprocess::check_run(driver, make_tool_arg(tool_arg), image, mountpoint, options, std::forward(args)...)) {