Skip to content

Releases: oskarirauta/netlink_cpp

v2.1.0

Choose a tag to compare

@github-actions github-actions released this 27 Jun 19:18
Release v2.1.0

A round of fixes from a full audit.

- fix memory leaks: add_number allocated `new void*[sz]` (wrong size) and never
  freed it - leaked on every numeric attribute (set_master/set_mtu/add_route/
  join_ns/...); send() leaked the 64 KB message buffer if an attribute append
  threw (both now use a local buffer / std::unique_ptr)
- fix the dead send error check: `size_t cnt = sendmsg(...)` made `cnt < 0`
  always false, so sendmsg failures were swallowed (now ssize_t)
- fix prefix::netmask() shifting by 32 for a /0 (undefined behaviour) - it
  returned 255.255.255.255 instead of 0.0.0.0
- fix a NULL dereference in interfaces(): getifaddrs() may return a NULL ifa_addr
- fix nl::netns fd ownership: copying shared the raw fd, risking a double close
  / fd reuse (copy and assignment now dup the descriptor)
- smaller fixes: attr::to_data() always threw; inet_pton checked < 0 instead of
  <= 0; signed isdigit()/shift undefined behaviour; recv() now validates the
  reply length before dereferencing the header
- update GitHub Actions (actions/checkout@v5, create/upload-asset actions @v2;
  drop the unnecessary submodule step - there are no submodules)
- README: fix a typo and add a usage example

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Signed-off-by: Oskari Rauta <oskari.rauta@gmail.com>

v2.0.0

Choose a tag to compare

@github-actions github-actions released this 05 Apr 13:38
Release version 2.0.0

A lot of fixes and improvements, includes also new nl::network which
can be used to display some statistics of current network configuration.
There's also a small example program to demonstrate how it works.

Signed-off-by: Oskari Rauta <oskari.rauta@gmail.com>

v1.0.0

Choose a tag to compare

@github-actions github-actions released this 21 Jan 19:04
Initial release v1.0.0

Signed-off-by: Oskari Rauta <oskari.rauta@gmail.com>