+2
−2
Loading
If the size returned from llistxattr/lgetxattr is 0, we skipped the malloc call, leaving xattr.value uninitialized. However, this value is later passed to `g_free` without any further checks, causing an error. Fix that by always calling g_malloc unconditionally. If `size` is 0, it will return NULL, which is safe to pass to g_free. Signed-off-by:Keno Fischer <keno@juliacomputing.com> Signed-off-by:
Greg Kurz <groug@kaod.org>