From: Austin Clements Date: Sun, 27 Jul 2014 03:52:41 +0000 (+2000) Subject: [PATCH 02/14] util: Make string-util.h C++-compatible X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=92d28a258650ce7fd3bb631afe382f4cef0dd08c;p=notmuch-archives.git [PATCH 02/14] util: Make string-util.h C++-compatible --- diff --git a/d3/8f69ead0f223a8067ccc3d65ce9c4e4993e73d b/d3/8f69ead0f223a8067ccc3d65ce9c4e4993e73d new file mode 100644 index 000000000..45a8ff2dc --- /dev/null +++ b/d3/8f69ead0f223a8067ccc3d65ce9c4e4993e73d @@ -0,0 +1,107 @@ +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 1310A431FD5 + for ; Sat, 26 Jul 2014 20:53:12 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -2.3 +X-Spam-Level: +X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5 + tests=[RCVD_IN_DNSWL_MED=-2.3] 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 PZKrv7i3NovY for ; + Sat, 26 Jul 2014 20:53:06 -0700 (PDT) +Received: from dmz-mailsec-scanner-7.mit.edu (dmz-mailsec-scanner-7.mit.edu + [18.7.68.36]) + (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) + (No client certificate requested) + by olra.theworths.org (Postfix) with ESMTPS id 75349431FBC + for ; Sat, 26 Jul 2014 20:53:06 -0700 (PDT) +X-AuditID: 12074424-f79146d00000067c-f8-53d477a04eb9 +Received: from mailhub-auth-2.mit.edu ( [18.7.62.36]) + (using TLS with cipher AES256-SHA (256/256 bits)) + (Client did not present a certificate) + by dmz-mailsec-scanner-7.mit.edu (Symantec Messaging Gateway) with SMTP + id 63.C1.01660.0A774D35; Sat, 26 Jul 2014 23:53:04 -0400 (EDT) +Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11]) + by mailhub-auth-2.mit.edu (8.13.8/8.9.2) with ESMTP id s6R3r2Ed014365; + Sat, 26 Jul 2014 23:53:03 -0400 +Received: from drake.dyndns.org + (216-15-114-40.c3-0.arl-ubr1.sbo-arl.ma.cable.rcn.com + [216.15.114.40]) (authenticated bits=0) + (User authenticated as amdragon@ATHENA.MIT.EDU) + by outgoing.mit.edu (8.13.8/8.12.4) with ESMTP id s6R3r0mL016390 + (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT); + Sat, 26 Jul 2014 23:53:02 -0400 +Received: from amthrax by drake.dyndns.org with local (Exim 4.77) + (envelope-from ) + id 1XBFW8-000519-6z; Sat, 26 Jul 2014 23:53:00 -0400 +From: Austin Clements +To: notmuch@notmuchmail.org +Subject: [PATCH 02/14] util: Make string-util.h C++-compatible +Date: Sat, 26 Jul 2014 23:52:41 -0400 +Message-Id: <1406433173-19169-3-git-send-email-amdragon@mit.edu> +X-Mailer: git-send-email 2.0.0 +In-Reply-To: <1406433173-19169-1-git-send-email-amdragon@mit.edu> +References: <1406433173-19169-1-git-send-email-amdragon@mit.edu> +X-Brightmail-Tracker: + H4sIAAAAAAAAA+NgFtrLIsWRmVeSWpSXmKPExsUixG6norug/EqwwbxFwhbXb85kdmD0eLbq + FnMAYxSXTUpqTmZZapG+XQJXxrTvT9gKvrFU7Pr5krGB8Q1zFyMnh4SAicTHz0ugbDGJC/fW + s4HYQgKzmSQmvNPpYuQCsjcySjS2TWCCcO4wSZy8foYVwpnLKDH/XT9YO5uAhsS2/csZQWwR + AWmJnXdnAxVxcDALqEn86VIBCQsL2ElMW/gXbAOLgKrElIfdLCA2r4CDRM+xFUwQV8hJNNz4 + BFbDKeAocfzZCTaQMUJANbcuJU5g5F/AyLCKUTYlt0o3NzEzpzg1Wbc4OTEvL7VI11wvN7NE + LzWldBMjOGRcVHYwNh9SOsQowMGoxMObwXYlWIg1say4MvcQoyQHk5Io734zoBBfUn5KZUZi + cUZ8UWlOavEhRgkOZiURXqFioBxvSmJlVWpRPkxKmoNFSZz3rbVVsJBAemJJanZqakFqEUxW + hoNDSYL3RhlQo2BRanpqRVpmTglCmomDE2Q4D9DwDaUgw4sLEnOLM9Mh8qcYdTkW7X/ZzSTE + kpeflyolzvsLpEgApCijNA9uDizWXzGKA70lzMsKso4HmCbgJr0CWsIEtITF/zLIkpJEhJRU + A6N05dTvgp96l5T8sSq9yr97MY/C+ZCP7spHi03WvQhYER7yiMV5w6Z54pISkh6/7zMyzNvW + Kq5i2bNm/1puw50n7m5n6XvbcmhW5uc/uz1CeXkzSt9x5ay3LJWquv90v+QFXd+i6hxBiYKw + KI7Gx11lWbM2sZpU3DvX83DKS19uC569/zSLApVYijMSDbWYi4oTAbTW9g/QAgAA +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: Sun, 27 Jul 2014 03:53:12 -0000 + +--- + util/string-util.h | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/util/string-util.h b/util/string-util.h +index 8a3ad19..ccad17f 100644 +--- a/util/string-util.h ++++ b/util/string-util.h +@@ -3,6 +3,10 @@ + + #include + ++#ifdef __cplusplus ++extern "C" { ++#endif ++ + /* like strtok(3), but without state, and doesn't modify s. Return + * value is indicated by pointer and length, not null terminator. + * +@@ -57,4 +61,8 @@ int + parse_boolean_term (void *ctx, const char *str, + char **prefix_out, char **term_out); + ++#ifdef __cplusplus ++} ++#endif ++ + #endif +-- +2.0.0 +