Re: [PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Joe Perches
On Tue, 2018-04-03 at 21:33 +0800, Xidong Wang wrote: > From: Xidong Wang <2711406...@qq.com> > > In function fbtft_framebuffer_alloc(), the memory allocated by > framebuffer_alloc() is not released on the error path that txbuflen > 0 > and txbuf, which holds the return value of devm_kzalloc(),

Re: [PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Joe Perches
On Tue, 2018-04-03 at 21:33 +0800, Xidong Wang wrote: > From: Xidong Wang <2711406...@qq.com> > > In function fbtft_framebuffer_alloc(), the memory allocated by > framebuffer_alloc() is not released on the error path that txbuflen > 0 > and txbuf, which holds the return value of devm_kzalloc(),

Re: [PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Dan Carpenter
There is a typo in the subject. It should be "Staging" instead of "taging:". On Tue, Apr 03, 2018 at 09:14:28PM +0800, Xidong Wang wrote: > From: Xidong Wang <2711406...@qq.com> > > In function fbtft_framebuffer_alloc(), the memory allocated by > framebuffer_alloc() is not released on the error

Re: [PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Dan Carpenter
There is a typo in the subject. It should be "Staging" instead of "taging:". On Tue, Apr 03, 2018 at 09:14:28PM +0800, Xidong Wang wrote: > From: Xidong Wang <2711406...@qq.com> > > In function fbtft_framebuffer_alloc(), the memory allocated by > framebuffer_alloc() is not released on the error

[PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Xidong Wang
From: Xidong Wang <2711406...@qq.com> In function fbtft_framebuffer_alloc(), the memory allocated by framebuffer_alloc() is not released on the error path that txbuflen > 0 and txbuf, which holds the return value of devm_kzalloc(), is NULL. This will result in a memory leak bug. Signed-off-by:

[PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Xidong Wang
From: Xidong Wang <2711406...@qq.com> In function fbtft_framebuffer_alloc(), the memory allocated by framebuffer_alloc() is not released on the error path that txbuflen > 0 and txbuf, which holds the return value of devm_kzalloc(), is NULL. This will result in a memory leak bug. Signed-off-by:

Re: [PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Greg Kroah-Hartman
On Tue, Apr 03, 2018 at 09:14:28PM +0800, Xidong Wang wrote: > From: Xidong Wang <2711406...@qq.com> > > In function fbtft_framebuffer_alloc(), the memory allocated by > framebuffer_alloc() is not released on the error path that txbuflen > 0 > and txbuf, which holds the return value of

Re: [PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Greg Kroah-Hartman
On Tue, Apr 03, 2018 at 09:14:28PM +0800, Xidong Wang wrote: > From: Xidong Wang <2711406...@qq.com> > > In function fbtft_framebuffer_alloc(), the memory allocated by > framebuffer_alloc() is not released on the error path that txbuflen > 0 > and txbuf, which holds the return value of

[PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Xidong Wang
From: Xidong Wang <2711406...@qq.com> In function fbtft_framebuffer_alloc(), the memory allocated by framebuffer_alloc() is not released on the error path that txbuflen > 0 and txbuf, which holds the return value of devm_kzalloc(), is NULL. This will result in a memory leak bug. Signed-off-by:

[PATCH 1/1] taging: fbtft: fix memory leak

2018-04-03 Thread Xidong Wang
From: Xidong Wang <2711406...@qq.com> In function fbtft_framebuffer_alloc(), the memory allocated by framebuffer_alloc() is not released on the error path that txbuflen > 0 and txbuf, which holds the return value of devm_kzalloc(), is NULL. This will result in a memory leak bug. Signed-off-by: