Hi, Przemysław Pawełczyk <[email protected]> writes:
> Extended attributes without value make metastore print error and exit, > prematurely ending update of .metastore file, thus corrupting it in > almost all imaginable cases (as long as xattrs are used, of course). Thanks for the report. > Zak Wilcox prepared a fix (http://git.io/JZnLLA), which I slightly > modified and commited to my repo, as David's one is defunct atm: > https://github.com/przemoc/metastore/commit/f75ca58c96 I fixed the issue with the following patch instead, which expresses the intent more clearly: --- a/metaentry.c +++ b/metaentry.c @@ -401,8 +401,9 @@ for (i = 0; i < mentry->xattrs; i++) { write_string(mentry->xattr_names[i], to); write_int(mentry->xattr_lvalues[i], 4, to); - write_binary_string(mentry->xattr_values[i], - mentry->xattr_lvalues[i], to); + if (mentry->xattr_lvalues[i]) + write_binary_string(mentry->xattr_values[i], + mentry->xattr_lvalues[i], to); } } } Cheers, -- Romain Francoise <[email protected]> http://people.debian.org/~rfrancoise/ -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected]

