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

Commit 5537f3dc authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "input: touchscreen: nt36xxx: Check buffer size"

parents 905db259 4312e3a6
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -1054,7 +1054,7 @@ const struct seq_operations nvt_selftest_seq_ops = {
static int32_t nvt_selftest_open(struct inode *inode, struct file *file)
{
	struct device_node *np = ts->client->dev.of_node;
	unsigned char mpcriteria[32] = {0};	//novatek-mp-criteria-default
	unsigned char mpcriteria[64] = {0};	//novatek-mp-criteria-default

	TestResult_Short = 0;
	TestResult_Open = 0;
@@ -1093,7 +1093,8 @@ static int32_t nvt_selftest_open(struct inode *inode, struct file *file)
		 * Ex. nvt_pid = 500A
		 *     mpcriteria = "novatek-mp-criteria-500A"
		 */
		snprintf(mpcriteria, PAGE_SIZE, "novatek-mp-criteria-%04X", ts->nvt_pid);
		snprintf(mpcriteria, sizeof(mpcriteria),
				"novatek-mp-criteria-%04X", ts->nvt_pid);

		if (nvt_mp_parse_dt(np, mpcriteria)) {
			mutex_unlock(&ts->lock);