This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
Re: libresolv with getaddrinfo (With valid bug report?)
- From: Florian Weimer <fw at deneb dot enyo dot de>
- To: Joshua Rogers <glibc at internot dot info>
- Cc: libc-help at sourceware dot org
- Date: Mon, 16 Mar 2015 21:49:33 +0100
- Subject: Re: libresolv with getaddrinfo (With valid bug report?)
- Authentication-results: sourceware.org; auth=none
- References: <5502EB12 dot 9030002 at internot dot info> <5502EC84 dot 1090201 at redhat dot com> <5502F419 dot 4060007 at internot dot info> <55032FE3 dot 2030109 at redhat dot com> <5503A2D8 dot 4070607 at internot dot info> <5503E790 dot 9090702 at internot dot info> <55040D73 dot 8090107 at internot dot info> <55041C5C dot 6080201 at internot dot info> <550436EE dot 6020905 at internot dot info>
* Joshua Rogers:
> I found *A* problem, I think.
>
> if ((ret == 0) && (last_mtime != statbuf.st_mtime)) {
>
> (gdb) p statbuf
> $3 = {st_dev = 16, st_ino = 16508, st_nlink = 1, st_mode = 33188, st_uid
> = 0, st_gid = 0, __pad0 = 0, st_rdev = 0, st_size = 172, st_blksize =
> 4096, st_blocks = 8, st_atim = {tv_sec = 1426334408, tv_nsec = 449405094},
> st_mtim = {tv_sec = 1426334407, tv_nsec = 73405066}, st_ctim = {tv_sec
> = 1426334407, tv_nsec = 73405066}, __glibc_reserved = {0, 0, 0}}
>
>
> There is no statbuf.st_mtime. It's st.mtim.
That's expected, see the header files. st_mtime is an alias for
st_mtim.tv_sec.