Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 640457db authored by Venkata Prahlad Valluru's avatar Venkata Prahlad Valluru Committed by Gerrit - the friendly Code Review server
Browse files

input: touchscreen: Fix buffer overflow issue in synaptics driver



Limit the index to buffer length while copying from
'strptr' to 'imagePR'.

Change-Id: Id78931c9c1f2c00b5d5c561b2ac83d947aa70bcc
Signed-off-by: default avatarVenkata Prahlad Valluru <vvalluru@codeaurora.org>
parent 31994032
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -865,7 +865,8 @@ static enum flash_area fwu_go_nogo(void)
		}

		strptr += 2;
		while (strptr[index] >= '0' && strptr[index] <= '9') {
		while ((index < MAX_FIRMWARE_ID_LEN - 1) && strptr[index] >= '0'
						&& strptr[index] <= '9') {
			imagePR[index] = strptr[index];
			index++;
		}