Permalink
Browse files
unix: fix dangling pointer free() bug
- Loading branch information
Showing
with
3 additions
and
0 deletions.
-
+3
−0
src/unix/core.c
|
@@ -634,6 +634,9 @@ int uv_getaddrinfo(uv_loop_t* loop, |
|
|
handle->hints = malloc(sizeof(struct addrinfo)); |
|
|
memcpy(&handle->hints, hints, sizeof(struct addrinfo)); |
|
|
} |
|
|
else { |
|
|
handle->hints = NULL; |
|
|
} |
|
|
|
|
|
/* TODO security! check lengths, check return values. */ |
|
|
|
|
|
0 comments on commit
37e8bf2