Re: [PATCH v2] ASoC: Add a sanity check before using dai driver name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 24, 2017 at 11:34 AM, Jeffy Chen <jeffy.chen@xxxxxxxxxxxxxx> wrote:
>                 list_for_each_entry(dai, &component->dai_list, list) {
>                         if (dlc->dai_name && strcmp(dai->name, dlc->dai_name)
> -                           && strcmp(dai->driver->name, dlc->dai_name))
> +                           && (!dai->driver->name
> +                               || !strcmp(dai->driver->name, dlc->dai_name))
>                                 continue;

If the dai->driver->name is match with the dlc->dai_name, does it need
to continue?

>
>                         return dai;
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux