public inbox for
 help / color / mirror / Atom feed
From: "河辺 岳人" <>
Cc: "河辺 岳人" <>
Subject: [PATCH] Retrive 64bit timestamp from curl_easy_getinfo on _TIME_BITS=64 environment
Date: Tue, 27 Sep 2022 21:10:39 +0900	[thread overview]
Message-ID: <> (raw)

On 32bit system compiled with -D_TIME_BITS=64, following tests failed:


due to tests/ failing on
"test $fileame -ot `pwd`", with LHS file having a bogus timestamp.
LHS is generated by debuginfo-find as a cache file.

I'm not sure the fix is the correct way, but
since -D_TIME_BITS=64 mandates -D_FILE_OFFSET_BITS=64 in glibc,
this does work on glibc environment.

Signed-off-by: Taketo Kabe <>
  ChangeLog                      | 5 +++++
  debuginfod/debuginfod-client.c | 4 ++++
  2 files changed, 9 insertions(+)

diff --git a/ChangeLog b/ChangeLog
index 5421f5b8..1f449d60 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2022-09-27  Taketo Kabe  <>
+	* debuginfod/debuginfod-client.c: Correctly get timestamp when
+	compiling with -D_TIME_BITS=64 on 32bit environment.
  2022-04-28  Di Chen  <>

  	* NEWS: Add readefl -D, --use-dynamic.
diff --git a/debuginfod/debuginfod-client.c b/debuginfod/debuginfod-client.c
index 5e5c140a..28ad04c0 100644
--- a/debuginfod/debuginfod-client.c
+++ b/debuginfod/debuginfod-client.c
@@ -1392,7 +1392,11 @@ debuginfod_query_server (debuginfod_client *c,

    /* we've got one!!!! */
    time_t mtime;
+#if defined(_TIME_BITS) && _TIME_BITS == 64
+  CURLcode curl_res = curl_easy_getinfo(verified_handle, CURLINFO_FILETIME_T, (void*) &mtime);
    CURLcode curl_res = curl_easy_getinfo(verified_handle, CURLINFO_FILETIME, (void*) &mtime);
    if (curl_res != CURLE_OK)
      mtime = time(NULL); /* fall back to current time */


             reply	other threads:[~2022-09-27 12:10 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-27 12:10 河辺 岳人 [this message]
2022-09-27 15:17 ` Frank Ch. Eigler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).