From 4a01a7982ca39967d2a3ad1cb5be3f9c1d81d80e Mon Sep 17 00:00:00 2001 From: Christian Heimes Date: Thu, 7 Dec 2017 11:25:09 +0100 Subject: [PATCH] Make valgrind check more useful * make valgrind now fails when valgrind detects a definitive memory leak * suppress a known memory leak in OpenLDAP's NSS module Signed-off-by: Christian Heimes --- Makefile | 10 +++++++++- Misc/python-ldap.supp | 10 ++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 150981c3..e4ff75ac 100644 --- a/Makefile +++ b/Makefile @@ -63,9 +63,17 @@ $(PYTHON_SUPP): exit 1; valgrind: build $(PYTHON_SUPP) - valgrind --leak-check=full \ + valgrind \ + --leak-check=full \ + --track-fds=yes \ --suppressions=$(PYTHON_SUPP) \ --suppressions=Misc/python-ldap.supp \ --gen-suppressions=all \ --log-file=build/valgrind.log \ $(PYTHON) setup.py test + + @grep -A7 "blocks are definitely lost" build/valgrind.log; \ + if [ $$? == 0 ]; then \ + echo "Found definitive leak, see build/valgrind.log"; \ + exit 1; \ + fi diff --git a/Misc/python-ldap.supp b/Misc/python-ldap.supp index de704466..3267fd05 100644 --- a/Misc/python-ldap.supp +++ b/Misc/python-ldap.supp @@ -27,6 +27,16 @@ ... } +{ + NSS backend leaks one string during first initialization + Memcheck:Leak + match-leak-kinds: definite + fun:malloc + fun:PL_strdup + fun:tlsm_init + ... +} + { Ignore possible leaks in exception initialization Memcheck:Leak pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy