All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Daeseok Youn <daeseok.youn@gmail.com>
Cc: gregkh@linuxfoundation.org, d@teklibre.com,
	paul.gortmaker@windriver.com, sara.bird.iar@gmail.com,
	standby24x7@gmail.com, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: frontier: fix memory leak in usb_alphatrack_probe()
Date: Fri, 7 Mar 2014 11:14:41 +0300	[thread overview]
Message-ID: <20140307081441.GD4774@mwanda> (raw)
In-Reply-To: <2118769.zIlmIgrC0S@daeseok-laptop.cloud.net>

On Fri, Mar 07, 2014 at 05:02:25PM +0900, Daeseok Youn wrote:
> 
> oldi_buffer and write_buffer need to free when usb_alphatrack_delete()
> is called.
> 
> Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
> ---
>  drivers/staging/frontier/alphatrack.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/staging/frontier/alphatrack.c b/drivers/staging/frontier/alphatrack.c
> index edd5cef..4d630da 100644
> --- a/drivers/staging/frontier/alphatrack.c
> +++ b/drivers/staging/frontier/alphatrack.c
> @@ -208,6 +208,8 @@ static void usb_alphatrack_delete(struct usb_alphatrack *dev)
>  	kfree(dev->ring_buffer);
>  	kfree(dev->interrupt_in_buffer);
>  	kfree(dev->interrupt_out_buffer);
> +	kfree(dev->oldi_buffer);
> +	kfree(dev->write_buffer);
>  	kfree(dev);		/* fixme oldi_buffer */
                                   ^^^^^^^^^^^^^^^^^
Remove this comment now?

regards,
dan carpenter


  reply	other threads:[~2014-03-07  8:15 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-07  8:02 [PATCH] staging: frontier: fix memory leak in usb_alphatrack_probe() Daeseok Youn
2014-03-07  8:14 ` Dan Carpenter [this message]
2014-03-07  8:20   ` DaeSeok Youn

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140307081441.GD4774@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=d@teklibre.com \
    --cc=daeseok.youn@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=paul.gortmaker@windriver.com \
    --cc=sara.bird.iar@gmail.com \
    --cc=standby24x7@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.