Re: [PATCH] ASoC: compress: Remove duplicated code

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

 



On 8/7/17 10:07 AM, Mark Brown wrote:
On Mon, Aug 07, 2017 at 09:18:09PM +0800, Donglin Peng wrote:

The value of the variable new_name is assigned repeatedly.

@@ -737,9 +737,6 @@ int snd_soc_new_compress(struct snd_soc_pcm_runtime
*rtd, int num)
        }

        /* check client and interface hw capabilities */
-       snprintf(new_name, sizeof(new_name), "%s %s-%d",
-                       rtd->dai_link->stream_name, codec_dai->name, num);
-

Are you sure that this is the assignment that should be deleted, and if
so why?  Note that it's both conditionally and unconditionally assigned
later on...  Some words in the commit log about why this copy is removed
would be helpful.

Thanks for the report. Yes, the logic escapes me as well, there were two separate changes from Liam and Richard Fitzgerald and I can't figure out why the reassignments of the variable new_name are required.
_______________________________________________
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