Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Kirill Smelkov
linux
Commits
8d6ff919
Commit
8d6ff919
authored
22 years ago
by
Jaroslav Kysela
Browse files
Options
Download
Email Patches
Plain Diff
ALSA update
- fixed returned structure in ctl_read/write
parent
79611bfd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
sound/core/control.c
sound/core/control.c
+2
-2
No files found.
sound/core/control.c
View file @
8d6ff919
...
...
@@ -454,7 +454,7 @@ static int snd_ctl_elem_read(snd_card_t *card, snd_ctl_elem_value_t *_control)
}
read_unlock
(
&
card
->
control_rwlock
);
if
(
result
>=
0
)
if
(
copy_to_user
(
_control
,
&
control
,
sizeof
(
control
)))
if
(
copy_to_user
(
_control
,
control
,
sizeof
(
*
control
)))
return
-
EFAULT
;
kfree
(
control
);
return
result
;
...
...
@@ -503,7 +503,7 @@ static int snd_ctl_elem_write(snd_ctl_file_t *file, snd_ctl_elem_value_t *_contr
read_unlock
(
&
card
->
control_rwlock
);
__unlocked:
if
(
result
>=
0
)
if
(
copy_to_user
(
_control
,
&
control
,
sizeof
(
control
)))
if
(
copy_to_user
(
_control
,
control
,
sizeof
(
*
control
)))
return
-
EFAULT
;
kfree
(
control
);
return
result
;
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment