Merge "ASoC: msm: Modify buf size check to prevent OOB error"
This commit is contained in:
commit
45c4f7d22f
1 changed files with 2 additions and 2 deletions
|
@ -339,7 +339,7 @@ static ssize_t audio_output_latency_dbgfs_write(struct file *file,
|
|||
{
|
||||
char *temp;
|
||||
|
||||
if (count > 2*sizeof(char)) {
|
||||
if (count != 2*sizeof(char)) {
|
||||
pr_err("%s: err count is more %zd\n", __func__, count);
|
||||
return -EINVAL;
|
||||
} else {
|
||||
|
@ -396,7 +396,7 @@ static ssize_t audio_input_latency_dbgfs_write(struct file *file,
|
|||
{
|
||||
char *temp;
|
||||
|
||||
if (count > 2*sizeof(char)) {
|
||||
if (count != 2*sizeof(char)) {
|
||||
pr_err("%s: err count is more %zd\n", __func__, count);
|
||||
return -EINVAL;
|
||||
} else {
|
||||
|
|
Loading…
Add table
Reference in a new issue