Fix crash in TCPSocket.open
Fix segfault crash observable with TCPSocket.open(nil, nil)
This commit is contained in:
parent
efb2d43637
commit
b148dfef5a
Notes:
git
2025-03-15 06:51:05 +00:00
@ -593,7 +593,7 @@ init_fast_fallback_inetsock_internal(VALUE v)
|
||||
arg->getaddrinfo_shared->notify = hostname_resolution_notifier;
|
||||
|
||||
arg->getaddrinfo_shared->node = arg->hostp ? ruby_strdup(arg->hostp) : NULL;
|
||||
arg->getaddrinfo_shared->service = ruby_strdup(arg->portp);
|
||||
arg->getaddrinfo_shared->service = arg->portp ? ruby_strdup(arg->portp) : NULL;
|
||||
arg->getaddrinfo_shared->refcount = arg->family_size + 1;
|
||||
|
||||
for (int i = 0; i < arg->family_size; i++) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user