diff options
-rw-r--r-- | common/host_command.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/common/host_command.c b/common/host_command.c index 9fbd2efffb..cad9fd94a9 100644 --- a/common/host_command.c +++ b/common/host_command.c @@ -534,7 +534,7 @@ static int host_command_read_memmap(struct host_cmd_handler_args *args) uint8_t size = p->size; if (size > EC_MEMMAP_SIZE || offset > EC_MEMMAP_SIZE || - offset + size > EC_MEMMAP_SIZE || size > args->response_size) + offset + size > EC_MEMMAP_SIZE || size > args->response_max) return EC_RES_INVALID_PARAM; /* Make sure switch data is initialized */ |