[Spice-devel] [PATCH spice-server] test-leaks: Checks some leaks using TLS

Christophe Fergeau cfergeau at redhat.com
Wed Mar 8 12:28:07 UTC 2017


On Wed, Mar 08, 2017 at 07:20:26AM -0500, Frediano Ziglio wrote:
> > 
> > On Tue, Mar 07, 2017 at 04:56:00PM +0000, Frediano Ziglio wrote:
> > > Verify stuff are freed correctly (like TLS context).
> > > The different PKI file required are generated with
> > > base values (localhost and rsa 1024).
> > > 
> > > Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
> > > ---
> > >  server/tests/Makefile.am         |  1 +
> > >  server/tests/pki/ca-cert.pem     | 16 ++++++++++++++++
> > >  server/tests/pki/server-cert.pem | 18 ++++++++++++++++++
> > >  server/tests/pki/server-key.pem  | 15 +++++++++++++++
> > >  server/tests/test-leaks.c        |  9 +++++++++
> > >  5 files changed, 59 insertions(+)
> > >  create mode 100644 server/tests/pki/ca-cert.pem
> > >  create mode 100644 server/tests/pki/server-cert.pem
> > >  create mode 100644 server/tests/pki/server-key.pem
> > > 
> > > diff --git a/server/tests/Makefile.am b/server/tests/Makefile.am
> > > index db23177..3f61faa 100644
> > > --- a/server/tests/Makefile.am
> > > +++ b/server/tests/Makefile.am
> > > @@ -1,6 +1,7 @@
> > >  NULL =
> > >  
> > >  AM_CPPFLAGS =					\
> > > +	-DSPICE_TOP_SRCDIR=\"$(abs_top_srcdir)\"\
> > 
> > Should we use g_test_build_filename() instead?
> > 
> > Acked-by: Christophe Fergeau <cfergeau at redhat.com>
> > 
> > Christophe
> > 
> 
> I considered it but I found overkilling at the moment:

Ok.

> - requires to include a glib.mk (which I didn't find on my installation
>   but only on glib sources). And this file should be then updated;

Updated from time to time I guess, I don't expect this needs to be
updated every week

> - requires to use different Makefile macros;
> - requires to setup some additional environment variable to
>   run the tests manually. This make a bit harder to debug the tests.

I think the additional env var is only needed for srcdir != builddir
builds when running the tests manually.

Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/spice-devel/attachments/20170308/c39e644d/attachment.sig>


More information about the Spice-devel mailing list