commit | fb8cd6481ffd126f35e9e146a0dcf0c4e8899f2e | [log] [tgz] |
---|---|---|
author | Changming Liu <liu.changm@northeastern.edu> | Tue May 26 00:39:21 2020 +0000 |
committer | Takashi Iwai <tiwai@suse.de> | Tue May 26 08:18:24 2020 +0200 |
tree | 11ad21509a11fbbde361a819ad867e7d54531236 | |
parent | 259eb82475316672a5d682a94dc8bdd53cf8d8c3 [diff] |
ALSA: hwdep: fix a left shifting 1 by 31 UB bug The "info.index" variable can be 31 in "1 << info.index". This might trigger an undefined behavior since 1 is signed. Fix this by casting 1 to 1u just to be sure "1u << 31" is defined. Signed-off-by: Changming Liu <liu.changm@northeastern.edu> Cc: <stable@vger.kernel.org> Link: https://lore.kernel.org/r/BL0PR06MB4548170B842CB055C9AF695DE5B00@BL0PR06MB4548.namprd06.prod.outlook.com Signed-off-by: Takashi Iwai <tiwai@suse.de>