diff --git a/extra/mandoc/build b/extra/mandoc/build index 17e4a3f1..702ca364 100755 --- a/extra/mandoc/build +++ b/extra/mandoc/build @@ -1,6 +1,7 @@ #!/bin/sh -e patch -p1 < mandoc-no-warn.patch +patch -p1 < fix-tbl-segfault.patch # Change default pager. sed 's,"more -s","less",g' main.c > _ diff --git a/extra/mandoc/checksums b/extra/mandoc/checksums index 309d3a97..4ce1bf85 100644 --- a/extra/mandoc/checksums +++ b/extra/mandoc/checksums @@ -1,2 +1,3 @@ 8219b42cb56fc07b2aa660574e6211ac38eefdbf21f41b698d3348793ba5d8f7 eaff34c03d1b6741cf6b24a394c63ad6096e4391578414b9da986294ee817a25 +12e6138be6ec2e8a34373876d8a5fce387a1d2b51a461ae20e1d98637af1d15c diff --git a/extra/mandoc/patches/fix-tbl-segfault.patch b/extra/mandoc/patches/fix-tbl-segfault.patch new file mode 100644 index 00000000..b3147c76 --- /dev/null +++ b/extra/mandoc/patches/fix-tbl-segfault.patch @@ -0,0 +1,20 @@ +--- tbl_term.c 2020-08-18 12:35:27.290953791 +0200 ++++ tbl_term.c 2020-08-18 12:35:23.450952148 +0200 +@@ -626,7 +626,7 @@ + + lw = cpp == NULL || cpn == NULL || + (cpn->pos != TBL_CELL_DOWN && +- (dpn == NULL || strcmp(dpn->string, "\\^") != 0)) ++ (dpn == NULL || dpn->pos == TBL_DATA_NONE || strcmp(dpn->string, "\\^") != 0)) + ? hw : 0; + tbl_direct_border(tp, BHORIZ * lw, + col->width + col->spacing / 2); +@@ -670,7 +670,7 @@ + + rw = cpp == NULL || cpn == NULL || + (cpn->pos != TBL_CELL_DOWN && +- (dpn == NULL || strcmp(dpn->string, "\\^") != 0)) ++ (dpn == NULL || dpn->pos == TBL_DATA_NONE || strcmp(dpn->string, "\\^") != 0)) + ? hw : 0; + + /* The line crossing at the end of this column. */ diff --git a/extra/mandoc/sources b/extra/mandoc/sources index d0125188..c5ca229e 100644 --- a/extra/mandoc/sources +++ b/extra/mandoc/sources @@ -1,2 +1,3 @@ https://fossies.org/linux/misc/mandoc-1.14.5.tar.gz patches/mandoc-no-warn.patch +patches/fix-tbl-segfault.patch