Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: rustyrussell/pettycoin
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 8c2a6a585a00
Choose a base ref
...
head repository: rustyrussell/pettycoin
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 964043b4be84
Choose a head ref
  • 2 commits
  • 3 files changed
  • 1 contributor

Commits on Aug 11, 2014

  1. test: set VG_TEST_ARGS correctly.

    Tests should not leak memory.
    
    Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
    rustyrussell committed Aug 11, 2014
    Copy the full SHA
    e72ba17 View commit details
  2. test: report reachable leaks.

    Valgrind doesn't exit with an error for reachable leaks, but we want to
    catch them.
    
    Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
    rustyrussell committed Aug 11, 2014
    Copy the full SHA
    964043b View commit details
Showing with 3 additions and 2 deletions.
  1. +1 −0 Makefile.in
  2. +1 −1 configure
  3. +1 −1 test/Makefile
1 change: 1 addition & 0 deletions Makefile.in
Original file line number Diff line number Diff line change
@@ -25,6 +25,7 @@ VERSION:=$(shell git describe --dirty --always 2>/dev/null || echo Unknown)
CFLAGS = @CFLAGS@ -I$(CCANDIR) -DVERSION=\"$(VERSION)\"
CC = @CC@
VALGRIND= @VALGRIND@
VALGRIND_TEST_ARGS = @VALGRIND_TEST_ARGS@
LDFLAGS = -O3 -flto
LDLIBS := -lcrypto -lrt
GENERATE_CFLAGS=-O3
2 changes: 1 addition & 1 deletion configure
Original file line number Diff line number Diff line change
@@ -41,7 +41,7 @@ done
CC=$(find_command CC gcc cc) || exit 1
CFLAGS=${CFLAGS:-"-g3 -ggdb -Wall -Wundef -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wold-style-definition -fstack-protector"}
if VALGRIND="$(find_command VALGRIND valgrind) -q --error-exitcode=99"; then
VALGRIND_TEST_ARGS="--track-origins=yes --leak-check=full --show-reachable=yes --suppressions=vg-suppressions"
VALGRIND_TEST_ARGS="--track-origins=yes --leak-check=full --show-reachable=yes --suppressions=test/vg-suppressions"
else
VALGRIND=""
VALGRIND_TEST_ARGS=""
2 changes: 1 addition & 1 deletion test/Makefile
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@ check: unit-check
unit-check: $(UNIT_TESTS)

$(UNIT_TESTS): check-test/%: test/%
@trap "rm -f unit.$*.out" EXIT; if $(VALGRIND) $(VALGRIND_TEST_ARGS) $< > unit.$*.out 2>&1; then printf "[UNIT] %-48s OK\n" $*; exit 0; else printf "[UNIT] %-48s FAIL\n" $*; cat unit.$*.out; exit 1; fi
@trap "rm -f unit.$*.out" EXIT; if $(VALGRIND) $(VALGRIND_TEST_ARGS) $< > unit.$*.out 2>&1; then if grep -q 'loss record' unit.$*.out; then printf "[UNIT] %-48s LEAK\n" $*; cat unit.$*.out; exit 1; else printf "[UNIT] %-48s OK\n" $*; exit 0; fi; else printf "[UNIT] %-48s FAIL\n" $*; cat unit.$*.out; exit 1; fi

test-bins: $(TEST_BINS)