capmt: adapter index fix for 'mode 1'
This commit is contained in:
parent
6fc3a46810
commit
985f3af0a6
1 changed files with 2 additions and 2 deletions
|
@ -1081,9 +1081,9 @@ handle_ca0(capmt_t *capmt) {
|
|||
continue;
|
||||
}
|
||||
|
||||
adapter = ev[i].data.u32;
|
||||
adapter = ev[i].data.u32 - 1;
|
||||
|
||||
if (adapter >= MAX_CA)
|
||||
if (adapter < 0 || adapter >= MAX_CA)
|
||||
continue;
|
||||
|
||||
recvsock = capmt->capmt_adapters[adapter].ca_sock;
|
||||
|
|
Loading…
Add table
Reference in a new issue