Skip to content

Conversation

@jimklimov
Copy link
Member

@jimklimov jimklimov commented Apr 24, 2025

There is a fair amount of ritual to memcpy() (for alignment) the socket structures for different address families, to extract the IP (or other) address from them with inet_ntop() afterwards. Relocating these methods into one spot allows to simplify repetitions of that code in NUT codebase, as well as commonly extend later (e.g. AF_UNIX?..) should we want to.

Follows up from #2915 (includes it) and #2847.

The problem seems to have been introduced in #2012 (part of NUT v2.8.2).

@jimklimov jimklimov added enhancement C-str Issues and PRs about C/C++ methods, headers and data types dealing with strings and memory blocks labels Apr 24, 2025
@jimklimov jimklimov added this to the 2.8.4 milestone Apr 24, 2025
…normally

Avoid firing up QEMU builders on the NUT CI farm, unless we want QEMU tests

Signed-off-by: Jim Klimov <jimklimov+nut@gmail.com>
@jimklimov jimklimov added the CI Entries related to continuous integration infrastructure (here CI = tools + scripts + recipes) label Apr 24, 2025
Signed-off-by: Jim Klimov <jimklimov+nut@gmail.com>
…s with NUT_WANT_INET_NTOP_XX macro [networkupstools#2916]

Signed-off-by: Jim Klimov <jimklimov+nut@gmail.com>
Signed-off-by: Jim Klimov <jimklimov+nut@gmail.com>
@jimklimov jimklimov merged commit 72fbc58 into networkupstools:master Apr 24, 2025
30 checks passed
@jimklimov jimklimov deleted the common-inet_ntopX branch April 24, 2025 22:22
@jimklimov jimklimov added impacts-release-2.8.2 Issues reported against NUT release 2.8.2 (maybe vanilla or with minor packaging tweaks) impacts-release-2.8.3 Issues reported against NUT release 2.8.3 (maybe vanilla or with minor packaging tweaks) labels Apr 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C-str Issues and PRs about C/C++ methods, headers and data types dealing with strings and memory blocks CI Entries related to continuous integration infrastructure (here CI = tools + scripts + recipes) enhancement impacts-release-2.8.2 Issues reported against NUT release 2.8.2 (maybe vanilla or with minor packaging tweaks) impacts-release-2.8.3 Issues reported against NUT release 2.8.3 (maybe vanilla or with minor packaging tweaks)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants