1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-28 00:21:52 +03:00

resolv: Replace __builtin_expect with __glibc_unlikely/__glibc_likely

This commit is contained in:
Florian Weimer
2017-04-19 14:29:11 +02:00
parent 3e2cf872a5
commit bee05c9d58
6 changed files with 41 additions and 20 deletions

View File

@ -356,7 +356,7 @@ __res_vinit(res_state statp, int preinit) {
statp->nsort = nsort;
(void) fclose(fp);
}
if (__builtin_expect(statp->nscount == 0, 0)) {
if (__glibc_unlikely (statp->nscount == 0)) {
statp->nsaddr.sin_addr = __inet_makeaddr(IN_LOOPBACKNET, 1);
statp->nsaddr.sin_family = AF_INET;
statp->nsaddr.sin_port = htons(NAMESERVER_PORT);