]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - sound/synth/emux/soundfont.c
[ALSA] fix NULL pointer dereference in sound/synth/emux/soundfont.c
[karo-tx-linux.git] / sound / synth / emux / soundfont.c
index 4c5754d4a2e800db960d98b51257bd2972257b18..56d48a1db2ddc1418338e3399f3ba41dd4435bdf 100644 (file)
@@ -195,7 +195,7 @@ snd_soundfont_load(struct snd_sf_list *sflist, const void __user *data,
                break;
        case SNDRV_SFNT_REMOVE_INFO:
                /* patch must be opened */
-               if (sflist->currsf) {
+               if (!sflist->currsf) {
                        snd_printk("soundfont: remove_info: patch not opened\n");
                        rc = -EINVAL;
                } else {