linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Yong Wang <yong.y.wang@linux.intel.com>
Cc: Matthew Garrett <mjg@redhat.com>, linux-input@vger.kernel.org
Subject: Re: [PATCH] Input: Free the right keymap
Date: Fri, 19 Mar 2010 23:00:40 -0700	[thread overview]
Message-ID: <20100320060040.GA27766@core.coreip.homeip.net> (raw)
In-Reply-To: <20100320044016.GA32767@ywang-moblin2.bj.intel.com>

On Sat, Mar 20, 2010 at 12:40:16PM +0800, Yong Wang wrote:
> map is allocated in sparse_keymap_setup() and it should be freed
> instead of keymap.
> 

Indeed, thank you Yung.

> Signed-off-by: Yong Wang <yong.y.wang@intel.com>
> ---
>  drivers/input/sparse-keymap.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/input/sparse-keymap.c b/drivers/input/sparse-keymap.c
> index e6bde55..f64e004 100644
> --- a/drivers/input/sparse-keymap.c
> +++ b/drivers/input/sparse-keymap.c
> @@ -163,7 +163,7 @@ int sparse_keymap_setup(struct input_dev *dev,
>  	return 0;
>  
>   err_out:
> -	kfree(keymap);
> +	kfree(map);
>  	return error;
>  
>  }

-- 
Dmitry

      reply	other threads:[~2010-03-20  6:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-20  4:40 [PATCH] Input: Free the right keymap Yong Wang
2010-03-20  6:00 ` Dmitry Torokhov [this message]

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=20100320060040.GA27766@core.coreip.homeip.net \
    --to=dmitry.torokhov@gmail.com \
    --cc=linux-input@vger.kernel.org \
    --cc=mjg@redhat.com \
    --cc=yong.y.wang@linux.intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).