From: Carl Worth <cworth@cworth.org>
To: Michal Sojka <sojkam1@fel.cvut.cz>, notmuch@notmuchmail.org
Subject: Re: [PATCH] Switch from random to sequential thread identifiers.
Date: Tue, 09 Feb 2010 11:19:54 -0800 [thread overview]
Message-ID: <87ljf2md2d.fsf@yoom.home.cworth.org> (raw)
In-Reply-To: <87r5oua2wv.fsf@steelpick.localdomain>
[-- Attachment #1: Type: text/plain, Size: 1096 bytes --]
On Tue, 09 Feb 2010 15:40:00 +0100, Michal Sojka <sojkam1@fel.cvut.cz> wrote:
> What about the following? This could also fix Sebastian's problem.
...
> +#define __STDC_FORMAT_MACROS
> +#include <inttypes.h>
...
> - sprintf (thread_id, "%016llx", notmuch->last_thread_id);
> + sprintf (thread_id, "%016"PRIx64, notmuch->last_thread_id);
Excellent! I did hesitate for a moment when typing "llx" into the format
string, but I had no idea what the correct thing to use was. I'm sure
glad to have access to such a knowledgeable community where I can learn
for the low cost of exposing my ignorance in public.
I did verify the above in a copy of WG14/N1124. For anyone that doesn't
recognize that, that's the draft from the C99 working group that I've
been told is remarkably similar to C99 but distinct in that it's freely
available[*]. I haven't verified the similarity, but I have found that
document quite useful in cases like this one.
Thanks for the fix. I'll likely push my change out now that I've added
this fix.
-Carl
[*] http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1124.pdf
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2010-02-09 19:20 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-08 19:42 [PATCH] Switch from random to sequential thread identifiers Carl Worth
2010-02-08 21:36 ` Carl Worth
2010-02-09 9:58 ` Sebastian Spaeth
2010-02-09 10:07 ` Sebastian Spaeth
2010-02-09 10:35 ` Sebastian Spaeth
2010-02-09 19:22 ` Carl Worth
2010-02-09 14:40 ` Michal Sojka
2010-02-09 19:19 ` Carl Worth [this message]
2010-02-09 19:30 ` Jed Brown
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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ljf2md2d.fsf@yoom.home.cworth.org \
--to=cworth@cworth.org \
--cc=notmuch@notmuchmail.org \
--cc=sojkam1@fel.cvut.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* 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.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
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).