[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87ldxnuw1s.wl-tiwai@suse.de>
Date: Wed, 13 Nov 2024 14:01:51 +0100
From: Takashi Iwai <tiwai@...e.de>
To: Baojun Xu <baojun.xu@...com>
Cc: <tiwai@...e.de>,
<robh+dt@...nel.org>,
<andriy.shevchenko@...ux.intel.com>,
<lgirdwood@...il.com>,
<perex@...ex.cz>,
<pierre-louis.bossart@...ux.intel.com>,
<shenghao-ding@...com>,
<navada@...com>,
<13916275206@....com>,
<v-hampiholi@...com>,
<v-po@...com>,
<linux-sound@...r.kernel.org>,
<linux-kernel@...r.kernel.org>,
<liam.r.girdwood@...el.com>,
<yung-chuan.liao@...ux.intel.com>,
<broonie@...nel.org>,
<antheas.dk@...il.com>,
<philm@...jaro.org>
Subject: Re: [PATCH v4] ALSA: hda/tas2781: Add speaker id check for ASUS projects
On Mon, 04 Nov 2024 10:31:38 +0100,
Baojun Xu wrote:
> + // Speaker id was needed for ASUS projects.
> + if (!strncmp(sub, TAS2781_ASUS_ID, sizeof(TAS2781_ASUS_ID))) {
Is this really correct? The sizeof(TAS2781_ASUS_ID) is 5, including
the terminating NUL. So this becomes equivalent with strcmp(), and
it doesn't check the sub-string.
thanks,
Takashi
Powered by blists - more mailing lists