Subject: Re: "gnutls" under Darwin (was: CVS commit: pkgsrc/security/gnutls)
To: None <>
From: Matthias Scheler <>
List: tech-pkg
Date: 01/24/2007 21:37:38
On Wed, Jan 24, 2007 at 04:30:19PM -0500, Todd Vierling wrote:
> I just verified, the sample code at that link doesn't even compile on
> modern gcc for the same reason I described:

The code in GnuTLS looks different. From the header file:

class credential {
         credentials( credentials& c);
         virtual void set_ptr(void *) = 0;

From the actual implementation:

credentials::credentials( credentials& c)
    this->type = c.type;
    this->set_ptr( c.ptr());

[Why are the using "this->" here? It's completely pointless.]

G++ under Mac OS X does for some weird reason not use the vtable in that
constructor. It instead tries to call the implementation of of the
set_ptr() method provided by the "credential" class. But that is of
course not defined because the method is pure virtual and only defined
in derived classes.

	Kind regards

Matthias Scheler