From: Tomi Ollila Date: Tue, 28 Oct 2014 09:33:02 +0000 (+0200) Subject: Re: [PATCH] cli: cast timeval fields to long for format X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=1d22c4c5d2dbddf67ad3d9efebd14da5872a75c8;p=notmuch-archives.git Re: [PATCH] cli: cast timeval fields to long for format --- diff --git a/ff/92d564d62df14f89e6b439f8ec8446a67a0a9a b/ff/92d564d62df14f89e6b439f8ec8446a67a0a9a new file mode 100644 index 000000000..60bf0fdec --- /dev/null +++ b/ff/92d564d62df14f89e6b439f8ec8446a67a0a9a @@ -0,0 +1,82 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id 720AB431FB6 + for ; Tue, 28 Oct 2014 02:33:27 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 0 +X-Spam-Level: +X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] + autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id Gh-56zaVc-Dc for ; + Tue, 28 Oct 2014 02:33:19 -0700 (PDT) +Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) + by olra.theworths.org (Postfix) with ESMTP id 45E96431FAE + for ; Tue, 28 Oct 2014 02:33:19 -0700 (PDT) +Received: from guru.guru-group.fi (localhost [IPv6:::1]) + by guru.guru-group.fi (Postfix) with ESMTP id 3F7B2100051; + Tue, 28 Oct 2014 11:33:02 +0200 (EET) +From: Tomi Ollila +To: Jani Nikula , notmuch@notmuchmail.org +Subject: Re: [PATCH] cli: cast timeval fields to long for format +In-Reply-To: <1414484246-19659-1-git-send-email-jani@nikula.org> +References: <1414484246-19659-1-git-send-email-jani@nikula.org> +User-Agent: Notmuch/0.18.1+130~ga61922f (http://notmuchmail.org) Emacs/24.3.1 + (x86_64-unknown-linux-gnu) +X-Face: HhBM'cA~ +MIME-Version: 1.0 +Content-Type: text/plain +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Tue, 28 Oct 2014 09:33:27 -0000 + +On Tue, Oct 28 2014, Jani Nikula wrote: + +> This hides platform differences between struct timeval field types. + +LGTM. + +Tomi + +> --- +> notmuch-insert.c | 2 +- +> 1 files changed, 1 insertions(+), 1 deletions(-) +> +> diff --git a/notmuch-insert.c b/notmuch-insert.c +> index 7074077..0d2d810 100644 +> --- a/notmuch-insert.c +> +++ b/notmuch-insert.c +> @@ -197,7 +197,7 @@ tempfilename (const void *ctx) +> gettimeofday (&tv, NULL); +> +> filename = talloc_asprintf (ctx, "%ld.M%ldP%d.%s", +> - tv.tv_sec, tv.tv_usec, pid, hostname); +> + (long) tv.tv_sec, (long) tv.tv_usec, pid, hostname); +> if (! filename) +> fprintf (stderr, "Error: %s\n", strerror (ENOMEM)); +> +> -- +> 1.7.2.5 +> +> _______________________________________________ +> notmuch mailing list +> notmuch@notmuchmail.org +> http://notmuchmail.org/mailman/listinfo/notmuch