--- /dev/null
+Return-Path: <jani@nikula.org>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by olra.theworths.org (Postfix) with ESMTP id DF66A431FBC\r
+ for <notmuch@notmuchmail.org>; Wed, 18 Apr 2012 07:20:30 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.7\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
+ tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+ by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id bejQzl-r9QJB for <notmuch@notmuchmail.org>;\r
+ Wed, 18 Apr 2012 07:20:21 -0700 (PDT)\r
+Received: from mail-qc0-f181.google.com (mail-qc0-f181.google.com\r
+ [209.85.216.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id D465E431FAE\r
+ for <notmuch@notmuchmail.org>; Wed, 18 Apr 2012 07:20:20 -0700 (PDT)\r
+Received: by qcsk26 with SMTP id k26so5645397qcs.26\r
+ for <notmuch@notmuchmail.org>; Wed, 18 Apr 2012 07:20:20 -0700 (PDT)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+ d=google.com; s=20120113;\r
+ h=from:to:cc:subject:in-reply-to:references:user-agent:date\r
+ :message-id:mime-version:content-type:x-gm-message-state;\r
+ bh=xj4ZY5F3J+wVVh7i9jxlYcIgnkKo2IrVm67/ZaCRdpU=;\r
+ b=Uukk6fO6U63cHoU3tQ5M1iNsWCY/DKPmj6dDVFnixDiKu/LtbeIUNi5leXQMYT5GTM\r
+ AOokorXPD9KKMXFuSemcUrzQ+8dJ1DBvmCocLGEu62gSdQEZFEMYsmFQuez/iRbSbBrW\r
+ T1giBHtN0lnjJgFaKQQ1OARyC5NFp5oolEMfyqeWhtaJHJGFHmVI2lQST4/do1j3xt3x\r
+ MnWL8vTDwXJkbPwZ0lRZMT+DW5gK9cH00EEtIfkPPPREo7uaXGwqRt8gYkmCpeTN2XDR\r
+ xVUb/3dYJ5XCgwYBhCxUPQd/85oB4KBOVDoR4pfnP8pGbOwnWPQmlv+AsFQRpcj2Assv\r
+ XAsQ==\r
+Received: by 10.224.187.2 with SMTP id cu2mr3647011qab.88.1334758820257;\r
+ Wed, 18 Apr 2012 07:20:20 -0700 (PDT)\r
+Received: from localhost (nikula.org. [92.243.24.172])\r
+ by mx.google.com with ESMTPS id i8sm46335592qah.4.2012.04.18.07.20.18\r
+ (version=SSLv3 cipher=OTHER); Wed, 18 Apr 2012 07:20:18 -0700 (PDT)\r
+From: Jani Nikula <jani@nikula.org>\r
+To: Felipe Contreras <felipe.contreras@gmail.com>\r
+Subject: Re: [PATCH v2 1/3] Add 'compose' command\r
+In-Reply-To:\r
+ <CAMP44s2Ukz=kDaPHYG+jzR3pDfZGP+6Ojqc4Xz5J8PxEd9fKcQ@mail.gmail.com>\r
+References: <1334752753-23970-1-git-send-email-felipe.contreras@gmail.com>\r
+ <1334752753-23970-2-git-send-email-felipe.contreras@gmail.com>\r
+ <873981chpj.fsf@nikula.org>\r
+ <CAMP44s2Ukz=kDaPHYG+jzR3pDfZGP+6Ojqc4Xz5J8PxEd9fKcQ@mail.gmail.com>\r
+User-Agent: Notmuch/0.11.1+222~ga47a98c (http://notmuchmail.org) Emacs/23.1.1\r
+ (i686-pc-linux-gnu)\r
+Date: Wed, 18 Apr 2012 14:20:16 +0000\r
+Message-ID: <87vckxazq7.fsf@nikula.org>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=us-ascii\r
+X-Gm-Message-State:\r
+ ALoCoQnLn4LVmWAfprdfWbnRaaeKW0ptl8MDoMddoOK8L6YqSDUQQvXtuNbBjzAfirQa7z8jDVDy\r
+Cc: Felipe Contreras <felipe.contreras@ngmail.com>, notmuch@notmuchmail.org\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Wed, 18 Apr 2012 14:20:31 -0000\r
+\r
+On Wed, 18 Apr 2012 16:34:30 +0300, Felipe Contreras <felipe.contreras@gmail.com> wrote:\r
+> On Wed, Apr 18, 2012 at 4:06 PM, Jani Nikula <jani@nikula.org> wrote:\r
+> \r
+> > Running "notmuch compose" more than once within a second would result in\r
+> > identical message ids for the messages, which is not a good idea. That's\r
+> > not likely in interactive use, but the notmuch cli is highly scriptable,\r
+> > so someone is bound to hit this.\r
+> >\r
+> > Some paranoid might also be worried about "leaking" the time you run\r
+> > "notmuch compose"... which may be different from the actual time you\r
+> > send the message.\r
+> \r
+> It's still better than the current situation; nothing. In any case,\r
+> people that have not needed this would not be affected; their UI would\r
+> override the Message-ID.\r
+> \r
+> So do you have a better suggestion for a Message-ID?\r
+\r
+The easy way would be to just use g_mime_utils_generate_message_id()\r
+[1]. It doesn't give you any control of the part before @, but I'm not\r
+sure if that really matters.\r
+\r
+Alternatively you can write your own according to e.g. [2]. Glib appears\r
+to have decent and portable support for pseudo random number\r
+generation. But why bother? I'd go with gmime.\r
+\r
+BR,\r
+Jani.\r
+\r
+\r
+[1] http://developer.gnome.org/gmime/stable/gmime-gmime-utils.html#g-mime-utils-generate-message-id\r
+[2] http://www.jwz.org/doc/mid.html\r