Created attachment 239138 [details] git diff of display.c does null check before writing to fp astro:accrete display.c Segmentation Fault occurs if program is executed in a directory without write privileges. Patch provided exits gracefully if *fp is NULL before fprintf's attempt to write to non-existent file.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=39191036a1f8c22f0d1424afa90f2f2559f124ad commit 39191036a1f8c22f0d1424afa90f2f2559f124ad Author: Muhammad Moinur Rahman <bofh@FreeBSD.org> AuthorDate: 2022-12-31 19:49:42 +0000 Commit: Muhammad Moinur Rahman <bofh@FreeBSD.org> CommitDate: 2022-12-31 21:58:55 +0000 astro/accrete: Fix RUNTIME Segmentation Fault occurs if program is executed in a directory without write privileges. Patch provided exits gracefully if *fp is NULL before fprintf's attempt to write to non-existent file. - Add LICENSE BSD3CLAUSE PR: 268661 Reported by: eylusion@gmail.com astro/accrete/Makefile | 3 +++ astro/accrete/files/patch-display.c (new) | 14 ++++++++++++++ 2 files changed, 17 insertions(+)
Committed with changes.