btrfs: zero out left over bytes after processing compression streams
authorChris Mason <clm@fb.com>
Sun, 30 Nov 2014 13:56:33 +0000 (08:56 -0500)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 30 Nov 2014 17:33:51 +0000 (09:33 -0800)
commit2f19cad94cee3c9bd52d0c9ca584ef506302fb7c
treeca1a69874842c86904ff6b66cb7430c818f2baa4
parent7a5a4f978750756755dc839014e13d1b088ccc8e
btrfs: zero out left over bytes after processing compression streams

Don Bailey noticed that our page zeroing for compression at end-io time
isn't complete.  This reworks a patch from Linus to push the zeroing
into the zlib and lzo specific functions instead of trying to handle the
corners inside btrfs_decompress_buf2page

Signed-off-by: Chris Mason <clm@fb.com>
Reviewed-by: Josef Bacik <jbacik@fb.com>
Reported-by: Don A. Bailey <donb@securitymouse.com>
cc: stable@vger.kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/btrfs/compression.c
fs/btrfs/compression.h
fs/btrfs/lzo.c
fs/btrfs/zlib.c