Skip to content

RFC: handle_announce_capabilities: set _client_caps in a loop

Uri Lublin requested to merge uril/vd_agent:ASLR into master

Currently RFC since:

  1. I'll need to rebase after Frediano's ASLR fix is pushed.
  2. Doing it in a loop is simple and clear. Perhaps there is even a simpler way to fix it.

This fixes the following compiler warning:

vdagent/vdagent.cpp: In member function 'bool VDAgent::handle_announce_capabilities(const VDAgentAnnounceCapabilities*, uint32_t)': vdagent/vdagent.cpp:1030:48: warning: taking address of packed member of 'VDAgentAnnounceCapabilities' may result in an unaligned pointer value [-Waddress-of-packed-member] 1030 | _client_caps.assign(announce_capabilities->caps, announce_capabilities->caps + caps_size); | ~~~~~~~~~~~~~~~~~~~~~~~^~~~

Merge request reports