You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

vtesto 999B

12345678910111213141516171819202122232425262728
  1. #!/bin/sh
  2. #
  3. # Run our testsuite under valgrind. Mostly it complains about core GNU libc
  4. # functions, but it does actually help find interesting stuff in our own code
  5. # from time to time.
  6. #
  7. QUIET="-q"
  8. BASEPATH=`dirname $0`
  9. while getopts "lj:" opt; do
  10. case $opt in
  11. l) OPTS="--leak-check=full --show-reachable=yes --num-callers=24 --suppressions=gpsbabel.supp" ; QUIET="";;
  12. j) LOG=$OPTARG;;
  13. esac
  14. done
  15. shift $(($OPTIND -1))
  16. if [ "x$LOG" = "x" ]; then
  17. PNAME="valgrind $OPTS --error-exitcode=125 $QUIET ./gpsbabel" ${BASEPATH}/testo $*
  18. else
  19. # By default valgrind output goes to file descriptor 2, stderr.
  20. # Some of our tests redirect file descriptor 2 to a file and compare it to an expected result.
  21. # These compares will fail if valgrind sends output to file descriptor 2.
  22. # This option avoids those valgrind induced miscompares by using an alternate file descriptor.
  23. PNAME="valgrind $OPTS --error-exitcode=125 $QUIET --log-fd=3 ./gpsbabel" ${BASEPATH}/testo $* 3>$LOG
  24. fi