summaryrefslogtreecommitdiffstats
path: root/sound/pci/ice1712
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2013-10-29 16:37:11 +0100
committerTakashi Iwai <tiwai@suse.de>2013-10-29 16:42:36 +0100
commite12483e0f3dbc32dad8fa1dc97efac22b6aee94f (patch)
tree53207314a9b65a25832427e0d835032f132f1ecc /sound/pci/ice1712
parent2026d24ef2ea8caad5e87662a58075e930ccab63 (diff)
downloadlinux-e12483e0f3dbc32dad8fa1dc97efac22b6aee94f.tar.bz2
ALSA: ak4114: Fix wrong register array size
The size of the register cache array is actually 6 instead of 7, as it caches up to AK4114_REG_INT1_MASK. This resulted in unexpected access out of array range, although most of them aren't so serious (just reading one more byte on the stack at snd_ak4114_create()). Also, the check of cache size was wrongly done by checking with sizeof() instead of ARRAY_SIZE(). Fixed this together. (And yes, hardcoded numbers are bad, but I keep the coding style as is for making it clear what this patch actually does.) Spotted by coverity among several CIDs, e.g. 711621. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/ice1712')
0 files changed, 0 insertions, 0 deletions