ubifs: Fix xattr_names length in exit paths
authorRichard Weinberger <richard@nod.at>
Tue, 20 Sep 2016 08:08:30 +0000 (10:08 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 28 Oct 2016 07:01:35 +0000 (03:01 -0400)
commitd98a0641c0d267ec7b20381885e92d353e5bfc48
tree3492a19134a64133ed2663747af0e90a4e0255a8
parent795422ec43a7888a997c39020a1874258cce79b9
ubifs: Fix xattr_names length in exit paths

commit 843741c5778398ea67055067f4cc65ae6c80ca0e upstream.

When the operation fails we also have to undo the changes
we made to ->xattr_names. Otherwise listxattr() will report
wrong lengths.

Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ubifs/xattr.c