Skip to content

Commit b172e0a

Browse files
elfringtiwai
authored andcommitted
ALSA: emux: Delete an unnecessary check before the function call "snd_sf_free"
The snd_sf_free() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <[email protected]> Signed-off-by: Takashi Iwai <[email protected]>
1 parent 1fac168 commit b172e0a

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

sound/synth/emux/emux.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -160,12 +160,8 @@ int snd_emux_free(struct snd_emux *emu)
160160
snd_emux_detach_seq_oss(emu);
161161
#endif
162162
snd_emux_detach_seq(emu);
163-
164163
snd_emux_delete_hwdep(emu);
165-
166-
if (emu->sflist)
167-
snd_sf_free(emu->sflist);
168-
164+
snd_sf_free(emu->sflist);
169165
kfree(emu->voices);
170166
kfree(emu->name);
171167
kfree(emu);

0 commit comments

Comments
 (0)