[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH] tests: virnettlscontexttest needs gnutls-2.6.0



On Mon, Jan 30, 2012 at 12:10:57PM -0700, Eric Blake wrote:
> On 01/30/2012 10:44 AM, Philipp Hahn wrote:
> > virnettlscontexttest uses gnutls_x509_crt_set_subject_alt_name() and
> > GNUTLS_FSAN_APPEND, which - according to
> > <http://www.gnu.org/software/gnutls/manual/gnutls.html> - are only
> > available since 2.6.0.
> > 
> > Since libvirt still works fine with gnutls-1.0.25 from RHEL5, only
> > enable the test when the version of GNUTLS is at least 2.6.0.
> > 
> > Signed-off-by: Philipp Hahn <hahn univention de>
> > ---
> >  tests/virnettlscontexttest.c |    2 +-
> >  1 files changed, 1 insertions(+), 1 deletions(-)
> > 
> > diff --git a/tests/virnettlscontexttest.c b/tests/virnettlscontexttest.c
> > index 51f75b4..6dd42d4 100644
> > --- a/tests/virnettlscontexttest.c
> > +++ b/tests/virnettlscontexttest.c
> > @@ -36,7 +36,7 @@
> >  #include "virsocketaddr.h"
> >  #include "gnutls_1_0_compat.h"
> >  
> > -#if !defined WIN32 && HAVE_LIBTASN1_H && !defined GNUTLS_1_0_COMPAT
> > +#if !defined WIN32 && HAVE_LIBTASN1_H && !defined GNUTLS_1_0_COMPAT && LIBGNUTLS_VERSION_NUMBER > 0x020600
> 
> Isn't that what GNUTLS_1_0_COMPAT is already doing?  That is,
> GNUTLS_1_0_COMPAT should only be defined if we are already dealing with
> a newer gnutls, and should not be present when using RHEL5 1.0.25.  What
> version of gnutls are you using, where this patch made a difference?

The GNUTLS_1_0_COMPAT code is only dealing with versions <= 2.0.0.

This check is making it more strict to also skip any version
in between 2.0.0 and 2.6.0

Perhaps, this allows us to now remove the GNUTLS_1_0_COMPAT, but I
can't remember if the 1.0.x GNUTLS had LIBGNUTLS_VERSION_NUMBER
defined or not.

Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]