mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 17:30:02 +00:00
ALSA: fireworks: Fix wrong value as argument for PTR_ERR()
The return value of memdup_user() should be passed to return correct error. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
51212eea4f
commit
ba06b2cbad
1 changed files with 1 additions and 1 deletions
|
@ -135,7 +135,7 @@ hwdep_write(struct snd_hwdep *hwdep, const char __user *data, long count,
|
|||
|
||||
buf = memdup_user(data, count);
|
||||
if (IS_ERR(buf))
|
||||
return PTR_ERR(data);
|
||||
return PTR_ERR(buf);
|
||||
|
||||
/* check seqnum is not for kernel-land */
|
||||
seqnum = be32_to_cpu(((struct snd_efw_transaction *)buf)->seqnum);
|
||||
|
|
Loading…
Reference in a new issue