Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
kernel/relay.c: revert "kernel/relay.c: fix potential memory leak"
This reverts commit ba62baf ("kernel/relay.c: fix potential memory leak"). This commit introduced a double free bug, because 'chan' is already freed by the line: kref_put(&chan->kref, relay_destroy_channel); This bug was found by syzkaller, using the BLKTRACESETUP ioctl. Link: http://lkml.kernel.org/r/[email protected] Fixes: ba62baf ("kernel/relay.c: fix potential memory leak") Signed-off-by: Eric Biggers <[email protected]> Reported-by: syzbot <[email protected]> Reviewed-by: Andrew Morton <[email protected]> Cc: Zhouyi Zhou <[email protected]> Cc: Jens Axboe <[email protected]> Cc: <[email protected]> [4.7+] Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>