summaryrefslogtreecommitdiff
path: root/sysutils
diff options
context:
space:
mode:
authorAdam Weinberger <adamw@FreeBSD.org>2023-03-01 17:05:40 -0500
committerAdam Weinberger <adamw@FreeBSD.org>2023-03-01 17:06:54 -0500
commita5994971c0c12e2404bd8de2019b6e2c8775b76c (patch)
treef2ae78c52145c392ffb6432ce618d10c636ff458 /sysutils
parent106a10231cf7afceb00e9c775458a72afc2705a7 (diff)
downloadfreebsd-ports-a5994971c0c12e2404bd8de2019b6e2c8775b76c.zip
sysutils/goaccess: Update to 1.7.1 (again)
Includes a fix for a wacky segfault involving our basename(3) being a snowflake.
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/goaccess/Makefile2
-rw-r--r--sysutils/goaccess/distinfo6
-rw-r--r--sysutils/goaccess/files/patch-src_parser.c38
3 files changed, 42 insertions, 4 deletions
diff --git a/sysutils/goaccess/Makefile b/sysutils/goaccess/Makefile
index 20683963a352..55ec4b33221a 100644
--- a/sysutils/goaccess/Makefile
+++ b/sysutils/goaccess/Makefile
@@ -1,5 +1,5 @@
PORTNAME= goaccess
-PORTVERSION= 1.7
+PORTVERSION= 1.7.1
CATEGORIES= sysutils
MASTER_SITES= https://tar.goaccess.io/
diff --git a/sysutils/goaccess/distinfo b/sysutils/goaccess/distinfo
index f258acd573f8..1906b9f4b991 100644
--- a/sysutils/goaccess/distinfo
+++ b/sysutils/goaccess/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1672545959
-SHA256 (goaccess-1.7.tar.gz) = a7549cb5bc78e99fb6c4f75aa53bed98403156123c08eeedef7831dafe87e676
-SIZE (goaccess-1.7.tar.gz) = 678718
+TIMESTAMP = 1677708077
+SHA256 (goaccess-1.7.1.tar.gz) = 3d6876d91d02816a93ad86e179369942d914a82bf09d6a6c02964ed7de48610d
+SIZE (goaccess-1.7.1.tar.gz) = 677872
diff --git a/sysutils/goaccess/files/patch-src_parser.c b/sysutils/goaccess/files/patch-src_parser.c
new file mode 100644
index 000000000000..5cacf7f48677
--- /dev/null
+++ b/sysutils/goaccess/files/patch-src_parser.c
@@ -0,0 +1,38 @@
+From 94fc846b7b7001bb9fecd22b7f698b6753915f0a Mon Sep 17 00:00:00 2001
+From: Adam Weinberger <adamw@adamw.org>
+Date: Wed, 1 Mar 2023 16:44:09 -0500
+Subject: [PATCH] Fix null pointer exception on FreeBSD (fixes #2476)
+
+---
+ src/parser.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/src/parser.c b/src/parser.c
+index c5ca3ae43..8670e0e70 100644
+--- src/parser.c
++++ src/parser.c
+@@ -134,7 +134,7 @@ set_glog (Logs * logs, const char *filename) {
+ GLog *tmp = NULL, *glog = NULL;
+ int newlen = 0;
+ char const *err;
+- char *fvh = NULL, *fn = (char *) filename;
++ char *fvh = NULL, *fn = NULL;
+
+ if (logs->size - 1 < logs->idx) {
+ newlen = logs->size + 1;
+@@ -147,6 +147,7 @@ set_glog (Logs * logs, const char *filename) {
+ logs->size = newlen;
+ }
+
++ fn = xstrdup (filename); /* ensure fn is a string */
+ glog = logs->glog;
+ glog[logs->idx].errors = xcalloc (MAX_LOG_ERRORS, sizeof (char *));
+ glog[logs->idx].filename = xstrdup (fn);
+@@ -161,6 +162,7 @@ set_glog (Logs * logs, const char *filename) {
+ logs->processed = &(glog[logs->idx].processed);
+ logs->filename = glog[logs->idx].filename;
+ logs->idx++;
++ free (fn);
+
+ return 0;
+ }