summaryrefslogtreecommitdiff
path: root/src/metaentry.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/metaentry.c')
-rw-r--r--src/metaentry.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/metaentry.c b/src/metaentry.c
index fdb7f71..25bb00f 100644
--- a/src/metaentry.c
+++ b/src/metaentry.c
@@ -266,11 +266,14 @@ mentry_create(const char *path)
continue;
mentry->xattr_names[i] = xstrdup(attr);
+ mentry->xattr_values[i] = NULL;
+
vsize = getxattr(path, attr, NULL, 0);
if (vsize < 0) {
msg(MSG_ERROR, "getxattr failed for %s: %s\n",
path, strerror(errno));
free(list);
+ mentry->xattrs = i + 1;
mentry_free(mentry);
return NULL;
}
@@ -283,6 +286,7 @@ mentry_create(const char *path)
msg(MSG_ERROR, "getxattr failed for %s: %s\n",
path, strerror(errno));
free(list);
+ mentry->xattrs = i + 1;
mentry_free(mentry);
return NULL;
}