mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
Fix crash in resolver on memory allocation failure (bug 23005)
This commit is contained in:
parent
5f45f96ad0
commit
f178e59fa5
@ -1,3 +1,9 @@
|
||||
2018-03-27 Andreas Schwab <schwab@suse.de>
|
||||
|
||||
[BZ #23005]
|
||||
* resolv/res_send.c (__res_context_send): Return ENOMEM if
|
||||
allocation of private copy of nsaddr_list fails.
|
||||
|
||||
2018-03-26 Joseph Myers <joseph@codesourcery.com>
|
||||
|
||||
[BZ #16552]
|
||||
|
@ -471,6 +471,11 @@ __res_context_send (struct resolv_context *ctx,
|
||||
'\0',
|
||||
sizeof (struct sockaddr_in6)
|
||||
- sizeof (struct sockaddr_in));
|
||||
else
|
||||
{
|
||||
__set_errno (ENOMEM);
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
EXT(statp).nscount = statp->nscount;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user