Dear ZSH community,
I just opened a Fedora bug[1], since I suspected this to a configuration-vs-facts
mistake in the build, but it turns out that this happens on debian, too, and that I can
see in the source code that the offending function is actually used – which should have
made linkage fail, but it only does so at dynamic runtime linking.
Don't really know how to go from there – someone would have to rework name resolution to
use getaddrinfo/freeaddrinfo (which is POSIX) instead of getipnodebyname/freehostent
(which isn't POSIX).
I see that this already happened, in 2007, in commit
a5187bb6ac96cc43f68367c5dc9332854c250713, "23670: use getaddrinfo() and getnameinfo()
instead of get*by* functions.", but was promptly reverted 30 minutes later without
explanation. Maybe it's time to revisit that? Maybe it's also just a sign that the code
hasn't been used by anyone in roughly forever, and deserves to be not built on the
platforms it doesn't support, or removed altogether.
Bug description:
when running `zmodload zsh/zftp`, it fails due to missing symbol `freehostent`. This is
worrisome, because a) that's a broken feature, and b) `freehostent` shouldn't be used on
glibc systems (far as I can tell) – `man freehostent` tells us that the function is
*not* present in glibc and deprecated.
Steps to Reproduce:
1. clean F37 or F38 or debian stable installation
2. `sudo dnf --refresh install -y zsh`
3. `zsh`
4. in zsh: `zmodload zsh/zftp`
Actual Results:
zsh: failed to load module `zsh/zftp': /usr/lib64/zsh/5.9/zsh/zftp.so: undefined symbol:
freehostent
Expected Results:
loading of module
Best regards,
Marcus Müller
[1] https://bugzilla.redhat.com/show_bug.cgi?id=2212160