musl - musl - an implementation of the standard library for Linux-based systems

index : musl
musl - an implementation of the standard library for Linux-based systems
summary refs log tree commit diff
path: root/src/stdlib/labs.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2022年10月20日 19:48:32 -0400
committerRich Felker <dalias@aerifal.cx>2022年10月20日 19:48:32 -0400
commit8f9259450aa43a6fd539e428e61e2961b725fbae (patch)
tree3e43cbb56606528a955933c14231e743ff513bb5 /src/stdlib/labs.c
parent63402be229facae2d0de9c5943a6ed25246fd021 (diff)
downloadmusl-8f9259450aa43a6fd539e428e61e2961b725fbae.tar.gz
fix return value of gethostby{name[2],addr} with no result but no error
commit f081d5336a80b68d3e1bed789cc373c5c3d6699b fixed gethostbyname[2]_r to treat negative results as a non-error, leaving gethostbyname[2] wrongly returning a pointer to the unfilled result buffer rather than a null pointer. since, as documented with commit fe82bb9b921be34370e6b71a1c6f062c20999ae0, the caller of gethostby{name[2],addr}_r can always rely on the result pointer being set, use that consistently rather than trying to duplicate logic about whether we have a result or not in gethostby{name[2],addr}.
Diffstat (limited to 'src/stdlib/labs.c')
0 files changed, 0 insertions, 0 deletions
generated by cgit v1.2.1 (git 2.18.0) at 2025年09月29日 18:56:48 +0000

AltStyle によって変換されたページ (->オリジナル) /