mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-12-23 06:02:37 +01:00
p2putil: Fix logic in required attribute check
The logic here intended to check whether all required attributes were available. However, it set the parse_error to true instead of have_required to false as intended.
This commit is contained in:
parent
5dbccee798
commit
a533734471
@ -720,7 +720,7 @@ static int p2p_parse_attrs(const uint8_t *pdu, size_t len, int type, ...)
|
|||||||
entry = e->data;
|
entry = e->data;
|
||||||
|
|
||||||
if (!entry->present && (entry->flags & ATTR_FLAG_REQUIRED)) {
|
if (!entry->present && (entry->flags & ATTR_FLAG_REQUIRED)) {
|
||||||
parse_error = true;
|
have_required = false;
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user