projects
/
p5sagit/p5-mst-13.2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
Downgrade Socket.pm's new inet_ntop and inet_pton to EXPORT_OK rather
[p5sagit/p5-mst-13.2.git]
/
ext
/
Socket
/
Socket.xs
diff --git
a/ext/Socket/Socket.xs
b/ext/Socket/Socket.xs
index
339b771
..
2d469ed
100644
(file)
--- a/
ext/Socket/Socket.xs
+++ b/
ext/Socket/Socket.xs
@@
-503,7
+503,8
@@
inet_pton(af, host)
ST(0) = sv_newmortal();
if (ok) {
- sv_setpvn( ST(0), (char *)&ip_address, sizeof ip_address );
+ sv_setpvn( ST(0), (char *)&ip_address,
+ af == AF_INET6 ? sizeof(ip_address) : sizeof(struct in_addr) );
}
#else
ST(0) = (SV *)not_here("inet_pton");