2021-06-07 18:57 UTC-0700 ~ Joe Stringer <joe@xxxxxxxxx> > Previously, if rst2man caught errors, then these would be ignored and > the output file would be written anyway. This would allow developers to > introduce regressions in the docs comments in the BPF headers. > > Additionally, even if you instruct rst2man to fail out, it will still > write out to the destination target file, so if you ran the tests twice > in a row it would always pass. Use a temporary file for the initial run > to ensure that if rst2man fails out under "--strict" mode, subsequent > runs will not automatically pass. > > Tested via ./tools/testing/selftests/bpf/test_doc_build.sh > > Signed-off-by: Joe Stringer <joe@xxxxxxxxx> Reviewed-by: Quentin Monnet <quentin@xxxxxxxxxxxxx>