nl80211: Fix error path in if_indices_reason reallocation
authorJouni Malinen <j@w1.fi>
Fri, 18 Mar 2016 14:25:35 +0000 (16:25 +0200)
committerJouni Malinen <j@w1.fi>
Fri, 18 Mar 2016 14:25:35 +0000 (16:25 +0200)
commit29eddc3d8cf824e058cccade7ffacf0cea109697
tree222573baadff2cb651bb6a3add7b691254a3512b
parent8c9aa2bc8d57aa04f5d59b0e5b7e764da31fb72c
nl80211: Fix error path in if_indices_reason reallocation

Commit 732b1d20ec06ab92fd22dbdea4609a6528bcf50a ('nl80211: Clean up
ifidx properly if interface in a bridge is removed') added
drv->if_indices_reason array similarly to the previously used
drv->if_indices. However, it had a copy-paste error here on the error
path where a reallocation failure after at least one successful
reallocation would result in the drv->if_indices being overridden
instead of restoring drv->if_indices_reason to the old value. Fix this
by setting the correct variable on the error path. (CID 138514)

Signed-off-by: Jouni Malinen <j@w1.fi>
src/drivers/driver_nl80211.c