Re: [PATCH] [media] rc: ttusbir: fix potential double free in ttusbir_probe()

2013-04-09 Thread Sean Young
On Tue, Apr 09, 2013 at 05:43:09PM +0800, Wei Yongjun wrote: > From: Wei Yongjun > > Since rc_unregister_device() frees its argument, the subsequently > call to rc_free_device() on the same variable will cause a double > free bug. Fix by set argument to NULL, thus when fall through to > rc_free_d

[PATCH] [media] rc: ttusbir: fix potential double free in ttusbir_probe()

2013-04-09 Thread Wei Yongjun
From: Wei Yongjun Since rc_unregister_device() frees its argument, the subsequently call to rc_free_device() on the same variable will cause a double free bug. Fix by set argument to NULL, thus when fall through to rc_free_device(), nothing will be done there. Signed-off-by: Wei Yongjun --- dr