Re: [PATCH] hynitron_cstxxx: Initialize tmp to 0 to fix uninitialized variable issue

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

 



On Thu, Nov 17, 2022 at 01:59:21PM -0600, Chris Morgan wrote:
> From: Chris Morgan <macromorgan@xxxxxxxxxxx>
> 
> In the very unlikely event the cst3xx_i2c_write() fails inside of the
> cst3xx_bootloader_enter() function 5 times in a row, the uninitalized
> value of tmp will get compared to CST3XX_BOOTLDR_CHK_VAL. Initialize
> the value of tmp to 0 so that in this unlikely event we are comparing
> 0 instead of an uninitalized variable.
> 
> Fixes: 66603243f528 ("Input: add driver for Hynitron cstxxx touchscreens")
> 
> Signed-off-by: Chris Morgan <macromorgan@xxxxxxxxxxx>
> Reported-by: Dan Carpenter <error27@xxxxxxxxx>

Applied, thank you.

-- 
Dmitry



[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux