From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 91C7F6DE141B for ; Wed, 1 May 2019 22:17:15 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -0.133 X-Spam-Level: X-Spam-Status: No, score=-0.133 tagged_above=-999 required=5 tests=[AWL=0.068, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id iKjUBqPMc5d8 for ; Wed, 1 May 2019 22:17:15 -0700 (PDT) Received: from che.mayfirst.org (che.mayfirst.org [162.247.75.118]) by arlo.cworth.org (Postfix) with ESMTPS id BBA136DE1333 for ; Wed, 1 May 2019 22:17:11 -0700 (PDT) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/simple; d=fifthhorseman.net; i=@fifthhorseman.net; q=dns/txt; s=2019; t=1556774230; h=from : to : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : from; bh=UjMZlMtE2Nd5kz46h2/y/OXOyGKC1FwIa4SadoQAjDQ=; b=Xjb7/kRuh8rWVHzIJah0HqnSd22rbkLjeKMDKsRjQDP0CJfXqfz1GRas bGLoTY8QCRqpJ5Ff3i3CzhNvvVdcDw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=fifthhorseman.net; i=@fifthhorseman.net; q=dns/txt; s=2019rsa; t=1556774229; h=from : to : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : from; bh=UjMZlMtE2Nd5kz46h2/y/OXOyGKC1FwIa4SadoQAjDQ=; b=xVzc1vagtPKmEr7HDS3tcqtDO88E1nEZMgrsGJ3jWBdwhELOSUJZNGEf dzLdi8XaiIqZ4w6KdXUkXTSc1FcRWW+CsvCFG68vkeYJLU1FwECQQoOC6w joYmKs5Q/b3zB1NS3VF7Quszg2/kwaBGiEQj5g5keSLugAq6nPuMJ2zXrx SSeuTD2suYDQL/ZaxjfHuHB/d5xgKPgdgfHb7W5rXxNZ1ZUFuWoAX4fC6q qcIzV/68JnC5umpzhQClkjA6jFmsPfZMHcxWslRRw2EXgu6JDIaamtYVn7 HSQULNdbKwsOdhoGxKZGUZG1x0+TguCxxF/bQknU/jIeqBa5Wo0sRQ== Received: from fifthhorseman.net (ool-6c3a0662.static.optonline.net [108.58.6.98]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by che.mayfirst.org (Postfix) with ESMTPSA id 7E326F9A3 for ; Thu, 2 May 2019 01:17:09 -0400 (EDT) Received: by fifthhorseman.net (Postfix, from userid 1000) id 6802D20D69; Thu, 2 May 2019 01:17:04 -0400 (EDT) From: Daniel Kahn Gillmor To: Notmuch Mail Subject: [PATCH 09/16] gmime-cleanup: drop unused gmime #defines and simplify g_mime_init () Date: Thu, 2 May 2019 01:16:46 -0400 Message-Id: <20190502051653.8502-10-dkg@fifthhorseman.net> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190502051653.8502-1-dkg@fifthhorseman.net> References: <20190501104643.5836-1-david@tethera.net> <20190502051653.8502-1-dkg@fifthhorseman.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.29 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: Thu, 02 May 2019 05:17:15 -0000 signed-off-by: Daniel Kahn Gillmor --- lib/database.cc | 2 +- lib/message-file.c | 2 +- notmuch.c | 2 +- util/gmime-extra.h | 7 ------- 4 files changed, 3 insertions(+), 10 deletions(-) diff --git a/lib/database.cc b/lib/database.cc index d2732f5e..1753117f 100644 --- a/lib/database.cc +++ b/lib/database.cc @@ -880,7 +880,7 @@ notmuch_database_open_verbose (const char *path, /* Initialize gmime */ if (! initialized) { - g_mime_init (GMIME_ENABLE_RFC2047_WORKAROUNDS); + g_mime_init (); initialized = 1; } diff --git a/lib/message-file.c b/lib/message-file.c index ac5545b3..214f3c1d 100644 --- a/lib/message-file.c +++ b/lib/message-file.c @@ -135,7 +135,7 @@ _notmuch_message_file_parse (notmuch_message_file_t *message) is_mbox = _is_mbox (message->file); if (! initialized) { - g_mime_init (GMIME_ENABLE_RFC2047_WORKAROUNDS); + g_mime_init (); initialized = 1; } diff --git a/notmuch.c b/notmuch.c index de85041b..eeb794e8 100644 --- a/notmuch.c +++ b/notmuch.c @@ -463,7 +463,7 @@ main (int argc, char *argv[]) local = talloc_new (NULL); - g_mime_init (GMIME_ENABLE_RFC2047_WORKAROUNDS); + g_mime_init (); #if !GLIB_CHECK_VERSION(2, 35, 1) g_type_init (); #endif diff --git a/util/gmime-extra.h b/util/gmime-extra.h index 60ae8765..e646efee 100644 --- a/util/gmime-extra.h +++ b/util/gmime-extra.h @@ -9,13 +9,8 @@ extern "C" { GMimeStream *g_mime_stream_stdout_new(void); -#define GMIME_ENABLE_RFC_2047_WORKAROUNDS 0xdeadbeef #define g_mime_content_type_to_string(c) g_mime_content_type_get_mime_type (c) #define g_mime_filter_crlf_new(encode,dots) g_mime_filter_dos2unix_new (FALSE) -#define g_mime_gpg_context_new(func,path) g_mime_gpg_context_new () -#define g_mime_gpg_context_set_use_agent(ctx,val) /*ignore*/ -#define g_mime_gpg_context_set_always_trust(ctx,val) /*ignore*/ -#define g_mime_init(flags) g_mime_init() #define g_mime_message_add_recipient(m,t,n,a) g_mime_message_add_mailbox (m,t,n,a) #define g_mime_message_set_subject(m,s) g_mime_message_set_subject(m,s,NULL) #define g_mime_multipart_signed_verify(mps,ctx,err) g_mime_multipart_signed_verify(mps, GMIME_ENCRYPT_NONE, err) @@ -23,8 +18,6 @@ GMimeStream *g_mime_stream_stdout_new(void); #define g_mime_object_set_header(o,h,v) g_mime_object_set_header (o,h,v,NULL) #define g_mime_parser_construct_message(p) g_mime_parser_construct_message (p, g_mime_parser_options_get_default ()) #define g_mime_part_get_content_object(p) g_mime_part_get_content (p) -#define g_mime_pkcs7_context_new(arg) g_mime_pkcs7_context_new() -#define g_mime_pkcs7_context_set_always_trust(ctx,val) /*ignore*/ #define g_mime_signature_get_errors(sig) g_mime_signature_get_status (sig) #define g_mime_utils_header_decode_text(txt) g_mime_utils_header_decode_text (NULL, txt) #define internet_address_to_string(ia,encode) internet_address_to_string (ia,NULL,encode) -- 2.20.1