[PATCH v2 2/2] Add pseudo-compatibility with gmime 2.6

Austin Clements amdragon at MIT.EDU
Wed Jan 18 09:35:34 PST 2012


Quoth Tomi Ollila on Jan 18 at 10:15 am:
> On Tue, 17 Jan 2012 17:25:46 -0500, Austin Clements <amdragon at MIT.EDU> wrote:
> > Quoth Thomas Jost on Jan 17 at 11:50 am:
> > >  
> > > +#ifdef GMIME_26
> > > +    /* sig_list may be created in both above cases, so we need to
> > > +     * cleanly handle it here. */
> > > +    if (node->sig_list) {
> > > +	GMimeSignatureList **proxy =
> > > +	    talloc (node, GMimeSignatureList *);
> > 
> > This doesn't need to be split into two lines.
> > 
> > > +	*proxy = node->sig_list;
> > > +	talloc_set_destructor (proxy, _signature_list_free);
> > > +    }
> > > +#else
> > >      if (node->verify_attempted && !node->sig_validity)
> > >  	fprintf (stderr, "Failed to verify signed part: %s\n",
> > >  		 (err ? err->message : "no error explanation given"));
> > > +#endif
> > 
> > I'd rather see the above as a separate #ifdef GMIME_26 and #ifndef
> > GMIME_26, since they aren't logical alternates of each other.
> 
> That reminds me that it should then be like GMIME_ATLEAST_26, so
> that this might be useful when GMIME > 2.6 is available...

Hopefully before GMIME 2.8 comes out, we'll be able to remove all of
the GMIME 2.4 compatibility.  But GMIME_ATLEAST_26 would be fine, too.


More information about the notmuch mailing list