Skip to content

Commit 623a6a9

Browse files
committed
codecoverage: also export CURLDIR during code coverage collection
This fixes coverage collection for standalone harnesses.
1 parent dbeae55 commit 623a6a9

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

codecoverage.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,15 @@ ${SCRIPTDIR}/handle_x.sh nghttp2 ${NGHTTPDIR} ${INSTALLDIR} || exit 1
3636
${SCRIPTDIR}/download_curl.sh /tmp/curlcov
3737

3838
# Move cURL to a subfolder of this folder to get the paths right.
39-
if [[ -d ${BUILD_ROOT}/curl ]]
39+
export CURLDIR=${BUILD_ROOT}/curl
40+
if [[ -d ${CURLDIR} ]]
4041
then
41-
rm -rf ${BUILD_ROOT}/curl
42+
rm -rf ${CURLDIR}
4243
fi
43-
mv /tmp/curlcov ${BUILD_ROOT}/curl
44+
mv /tmp/curlcov ${CURLDIR}
4445

4546
# Compile and install cURL to a second folder with code coverage.
46-
${SCRIPTDIR}/install_curl.sh -c ${BUILD_ROOT}/curl ${INSTALLDIR}
47+
${SCRIPTDIR}/install_curl.sh -c ${CURLDIR} ${INSTALLDIR}
4748

4849
# Compile and test the fuzzer with code coverage
4950
${SCRIPTDIR}/compile_fuzzer.sh -c ${INSTALLDIR}

0 commit comments

Comments
 (0)