diff --git a/src/filed/fd_plugins.c b/src/filed/fd_plugins.c index 39973e507ac..8cda513df9e 100644 --- a/src/filed/fd_plugins.c +++ b/src/filed/fd_plugins.c @@ -1319,7 +1319,9 @@ bxattr_exit_code plugin_build_xattr_streams(JCR *jcr, FF_PKT *ff_pkt) { Plugin *plugin; +#if defined(HAVE_XATTR) alist *xattr_value_list = NULL; +#endif bxattr_exit_code retval = bxattr_exit_error; Dmsg0(dbglvl, "plugin_build_xattr_streams\n"); @@ -1451,8 +1453,10 @@ bxattr_exit_code plugin_parse_xattr_streams(JCR *jcr, char *content, uint32_t content_length) { +#if defined(HAVE_XATTR) Plugin *plugin; alist *xattr_value_list = NULL; +#endif bxattr_exit_code retval = bxattr_exit_error; Dmsg0(dbglvl, "plugin_parse_xattr_streams\n"); @@ -1460,9 +1464,9 @@ bxattr_exit_code plugin_parse_xattr_streams(JCR *jcr, if (!jcr->plugin_ctx) { return bxattr_exit_ok; } - plugin = (Plugin *)jcr->plugin_ctx->plugin; #if defined(HAVE_XATTR) + plugin = (Plugin *)jcr->plugin_ctx->plugin; if (plug_func(plugin)->setXattr != NULL) { xattr_t *current_xattr; struct xattr_pkt xp; @@ -1497,9 +1501,7 @@ bxattr_exit_code plugin_parse_xattr_streams(JCR *jcr, retval = bxattr_exit_ok; } -#endif -#if defined(HAVE_XATTR) bail_out: if (xattr_value_list) { xattr_drop_internal_table(xattr_value_list);