P2P: Provide mechanism for figuring out p2p_scan_ie() buffer need
The new function, p2p_scan_ie_buf_len(), can be used to figure out how large a buffer needs to be allocated for p2p_scan_ie() use. This makes it easier to add new data into the buffer without forcing all callers to be updated to use a larger buffer.
This commit is contained in:
parent
fc6997b345
commit
206e1f422f
5 changed files with 24 additions and 4 deletions
|
@ -2462,6 +2462,12 @@ void p2p_scan_ie(struct p2p_data *p2p, struct wpabuf *ies)
|
|||
}
|
||||
|
||||
|
||||
size_t p2p_scan_ie_buf_len(struct p2p_data *p2p)
|
||||
{
|
||||
return 100;
|
||||
}
|
||||
|
||||
|
||||
int p2p_ie_text(struct wpabuf *p2p_ie, char *buf, char *end)
|
||||
{
|
||||
return p2p_attr_text(p2p_ie, buf, end);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue