ALSA: aloop: make read-only array texts static const
Subsystems (2)
PATCH 1/1 ALSA: aloop: make read-only array texts static const
Don't populate the read-only const array texts on the stack at run time, instead make it static.
Signed-off-by Colin Ian King <[email protected]>
--- sound/drivers/aloop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/drivers/aloop.c +1 -1
@@ -1668,7 +1668,7 @@ static int loopback_channels_get(struct snd_kcontrol *kcontrol,static int loopback_access_info (struct snd_kcontrol *kcontrol,struct snd_ctl_elem_info *uinfo) { -const char *const texts[] = {"Interleaved" ,"Non-interleaved" }; +static const char *const texts[] = {"Interleaved" ,"Non-interleaved" };return snd_ctl_enum_info (uinfo,1 ,ARRAY_SIZE (texts), texts); }
Signature · 1 line
2.53.0
Quoted 5 lines · Colin Ian King
Don't populate the read-only const array texts on the stack at run time, instead make it static.
Signed-off-by Colin Ian King <[email protected]>
Applied now. Thanks.
Takashi