Re: [PATCH 4/4] Explicitly type void* pointers
authorJani Nikula <jani@nikula.org>
Sun, 15 Apr 2012 21:05:58 +0000 (00:05 +0300)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:46:26 +0000 (09:46 -0800)
eb/06fccc8aa4cb1baf699d52fb7dc455108e9328 [new file with mode: 0644]

diff --git a/eb/06fccc8aa4cb1baf699d52fb7dc455108e9328 b/eb/06fccc8aa4cb1baf699d52fb7dc455108e9328
new file mode 100644 (file)
index 0000000..735cadb
--- /dev/null
@@ -0,0 +1,137 @@
+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 C74A8431FAF\r
+       for <notmuch@notmuchmail.org>; Sun, 15 Apr 2012 14:06:04 -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 Lotpo0hafFX1 for <notmuch@notmuchmail.org>;\r
+       Sun, 15 Apr 2012 14:06:04 -0700 (PDT)\r
+Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com\r
+       [209.85.217.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id B289D431FAE\r
+       for <notmuch@notmuchmail.org>; Sun, 15 Apr 2012 14:06:03 -0700 (PDT)\r
+Received: by lbdb5 with SMTP id b5so603142lbd.26\r
+       for <notmuch@notmuchmail.org>; Sun, 15 Apr 2012 14:06:02 -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:date:message-id\r
+       :mime-version:content-type:x-gm-message-state;\r
+       bh=643sXsUpn03EVD9qiFkVQNYo+ddDnwzgzCFiCDn0rqI=;\r
+       b=hkphcYoRI0Dv0+6pAZSOv/fGMgio7t/4MXL3zHqHoxUUKpkVG9S1NdxqylXLcuWRFD\r
+       pY5UzwrlkHq+veueC3YgYxhdvMhqCyhwuOifkcRWYyczWGtB2DsWeIfbLD55599c+l9q\r
+       D0sgpn/QqDE8xh1djbte89YlNluTth6XgKYoYEg4IxUL8kiAGTUJ4I2rjx8yvtYuVq55\r
+       2wb8PQhlKg1Ii0WM9kAz0Nsa/qyz4ASkotuym3WJEfxCHSKT9y1NZA6y6SS0XMLiLvOo\r
+       +iGtpuojk4LAz386+L5BTE7ua6MCZXlWgiowVUSDUyW5aDnuYd7s73V1aZu/v/2wj4nF\r
+       fJ2A==\r
+Received: by 10.152.128.137 with SMTP id no9mr7815927lab.2.1334523962127;\r
+       Sun, 15 Apr 2012 14:06:02 -0700 (PDT)\r
+Received: from localhost (dsl-hkibrasgw4-fe50dc00-68.dhcp.inet.fi.\r
+       [80.220.80.68])\r
+       by mx.google.com with ESMTPS id j6sm21791833lbm.1.2012.04.15.14.05.59\r
+       (version=SSLv3 cipher=OTHER); Sun, 15 Apr 2012 14:06:00 -0700 (PDT)\r
+From: Jani Nikula <jani@nikula.org>\r
+To: Vladimir.Marek@oracle.com, notmuch@notmuchmail.org\r
+Subject: Re: [PATCH 4/4] Explicitly type void* pointers\r
+In-Reply-To: <1333966665-10469-5-git-send-email-Vladimir.Marek@oracle.com>\r
+References: <1333966665-10469-1-git-send-email-Vladimir.Marek@oracle.com>\r
+       <1333966665-10469-5-git-send-email-Vladimir.Marek@oracle.com>User-Agent:\r
+       Notmuch/0.12+81~g839a805 (http://notmuchmail.org) Emacs/23.3.1\r
+       (i686-pc-linux-gnu)\r
+Date: Mon, 16 Apr 2012 00:05:58 +0300\r
+Message-ID: <87lilwk8nd.fsf@nikula.org>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=us-ascii\r
+X-Gm-Message-State:\r
+ ALoCoQnPrayHBho5/JmIcwxA4TPB62A0fD94gLCZXClzG1VoG3Du+kvE4FgasXWV5FaqBFDk4eYy\r
+Cc: Vladimir Marek <vlmarek@volny.cz>\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: Sun, 15 Apr 2012 21:06:04 -0000\r
+\r
+\r
+I tagged this patch notmuch::obsolete (see [1]) as the template\r
+workaround was pushed to master (commit\r
+de0557477d908be26615e8fda9f5eb62bed68b65).\r
+\r
+Jani.\r
+\r
+\r
+[1] http://nmbug.tethera.net/status/\r
+\r
+\r
+On Mon, 09 Apr 2012, Vladimir.Marek@oracle.com wrote:\r
+> From: Vladimir Marek <vlmarek@volny.cz>\r
+>\r
+>\r
+> Signed-off-by: Vladimir Marek <vlmarek@volny.cz>\r
+> ---\r
+>  lib/database.cc |    2 +-\r
+>  lib/message.cc  |    2 +-\r
+>  lib/thread.cc   |    2 +-\r
+>  3 files changed, 3 insertions(+), 3 deletions(-)\r
+>\r
+> diff --git a/lib/database.cc b/lib/database.cc\r
+> index 16c4354..3c82632 100644\r
+> --- a/lib/database.cc\r
+> +++ b/lib/database.cc\r
+> @@ -1361,7 +1361,7 @@ _resolve_message_id_to_thread_id (notmuch_database_t *notmuch,\r
+>      return status;\r
+>  \r
+>      if (message) {\r
+> -    *thread_id_ret = talloc_steal (ctx,\r
+> +    *thread_id_ret = (const char*)talloc_steal (ctx,\r
+>                                     notmuch_message_get_thread_id (message));\r
+>  \r
+>      notmuch_message_destroy (message);\r
+> diff --git a/lib/message.cc b/lib/message.cc\r
+> index 0075425..d56d442 100644\r
+> --- a/lib/message.cc\r
+> +++ b/lib/message.cc\r
+> @@ -220,7 +220,7 @@ _notmuch_message_create_for_message_id (notmuch_database_t *notmuch,\r
+>                                                                          message_id,\r
+>                                                                          &message);\r
+>      if (message)\r
+> -    return talloc_steal (notmuch, message);\r
+> +    return (notmuch_message_t*) talloc_steal (notmuch, message);\r
+>      else if (*status_ret)\r
+>      return NULL;\r
+>  \r
+> diff --git a/lib/thread.cc b/lib/thread.cc\r
+> index e976d64..d41ff3e 100644\r
+> --- a/lib/thread.cc\r
+> +++ b/lib/thread.cc\r
+> @@ -225,7 +225,7 @@ _thread_add_message (notmuch_thread_t *thread,\r
+>      char *clean_author;\r
+>  \r
+>      _notmuch_message_list_add_message (thread->message_list,\r
+> -                                   talloc_steal (thread, message));\r
+> +                                   (_notmuch_message*)talloc_steal (thread, message));\r
+>      thread->total_messages++;\r
+>  \r
+>      g_hash_table_insert (thread->message_hash,\r
+> -- \r
+> 1.7.3.2\r
+>\r
+> _______________________________________________\r
+> notmuch mailing list\r
+> notmuch@notmuchmail.org\r
+> http://notmuchmail.org/mailman/listinfo/notmuch\r