diff options
author | Florian Weimer <fweimer@redhat.com> | 2017-07-03 20:31:23 +0200 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2017-07-03 20:57:28 +0200 |
commit | f30a54b21b83f254533c59ca72ad17af5249c6be (patch) | |
tree | 174c6e8b77d8fc1514f4108e3290b91d19d838a6 /resolv/bits | |
parent | 352f4ff9a268b81ef5d4b2413f582565806e4790 (diff) | |
download | glibc-f30a54b21b83f254533c59ca72ad17af5249c6be.tar glibc-f30a54b21b83f254533c59ca72ad17af5249c6be.tar.gz glibc-f30a54b21b83f254533c59ca72ad17af5249c6be.tar.bz2 glibc-f30a54b21b83f254533c59ca72ad17af5249c6be.zip |
resolv: Introduce struct resolv_conf with extended resolver state
This change provides additional resolver configuration state which
is not exposed through the _res ABI. It reuses the existing
initstamp field in the supposedly-private part of _res. Some effort
is undertaken to avoid memory safety issues introduced by applications
which directly patch the _res object.
With this commit, only the initstamp field is moved into struct
resolv_conf. Additional members will be added later, eventually
migrating the entire resolver configuration.
Diffstat (limited to 'resolv/bits')
-rw-r--r-- | resolv/bits/types/res_state.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/resolv/bits/types/res_state.h b/resolv/bits/types/res_state.h index cee4b6ddd0..2544a627f6 100644 --- a/resolv/bits/types/res_state.h +++ b/resolv/bits/types/res_state.h @@ -47,10 +47,10 @@ struct __res_state { uint16_t nsinit; struct sockaddr_in6 *nsaddrs[MAXNS]; #ifdef _LIBC - unsigned long long int initstamp + unsigned long long int __glibc_extension_index __attribute__((packed)); #else - unsigned int _initstamp[2]; + unsigned int __glibc_reserved[2]; #endif } _ext; } _u; |