Convert os_realloc() for an array to use os_realloc_array()
Signed-hostap: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
b0cda9bd46
commit
067ffa2696
21 changed files with 88 additions and 86 deletions
|
@ -946,8 +946,8 @@ int eap_peer_select_phase2_methods(struct eap_peer_config *config,
|
|||
"method '%s'", start);
|
||||
} else {
|
||||
num_methods++;
|
||||
_methods = os_realloc(methods,
|
||||
num_methods * sizeof(*methods));
|
||||
_methods = os_realloc_array(methods, num_methods,
|
||||
sizeof(*methods));
|
||||
if (_methods == NULL) {
|
||||
os_free(methods);
|
||||
os_free(buf);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue