aboutsummaryrefslogtreecommitdiff
path: root/x11/xedit
diff options
context:
space:
mode:
authorNiclas Zeising <zeising@FreeBSD.org>2019-09-14 10:33:59 +0000
committerNiclas Zeising <zeising@FreeBSD.org>2019-09-14 10:33:59 +0000
commit7c492f5ab81c6a908d023aaf8706a2116ef10739 (patch)
tree36c5b0dabce2ae1a0596a73fb956ee06dc0cd1f1 /x11/xedit
parent39b58b6fee208fd4a7a0a6faa77b922f2e131ae0 (diff)
downloadports-7c492f5ab81c6a908d023aaf8706a2116ef10739.tar.gz
ports-7c492f5ab81c6a908d023aaf8706a2116ef10739.zip
x11/xedit: Fix segfault with missing tags file
Notes
Notes: svn path=/head/; revision=512004
Diffstat (limited to 'x11/xedit')
-rw-r--r--x11/xedit/Makefile10
-rw-r--r--x11/xedit/files/patch-util.c27
2 files changed, 35 insertions, 2 deletions
diff --git a/x11/xedit/Makefile b/x11/xedit/Makefile
index 7316b950ca19..87b1fd681f0d 100644
--- a/x11/xedit/Makefile
+++ b/x11/xedit/Makefile
@@ -2,12 +2,18 @@
PORTNAME= xedit
PORTVERSION= 1.2.2
+PORTREVISION= 1
CATEGORIES= x11
MAINTAINER= x11@FreeBSD.org
COMMENT= Simple text editor for X
-XORG_CAT= app
-USE_XORG= xt xaw7
+LICENSE= MIT BSD3CLAUSE
+LICENSE_COMB= multi
+LICENSE_FILE= ${WRKSRC}/COPYING
+
+USES= xorg-cat:app xorg
+
+USE_XORG= x11 xmu xt xaw7
.include <bsd.port.mk>
diff --git a/x11/xedit/files/patch-util.c b/x11/xedit/files/patch-util.c
new file mode 100644
index 000000000000..22ec83b7c17c
--- /dev/null
+++ b/x11/xedit/files/patch-util.c
@@ -0,0 +1,27 @@
+--- util.c.orig 2015-02-21 21:42:33 UTC
++++ util.c
+@@ -506,13 +506,14 @@ ResolveName(char *filename)
+
+ if (result == NULL && errno == ENOENT) {
+ int length;
+- char *dir, *file;
++ char *dir, *file, *fname;
+
+ length = strlen(filename);
+ tmp = dir = XtMalloc(length + 1);
+ strcpy(dir, filename);
++ fname = strdup(filename);
+
+- file = basename(filename);
++ file = basename(fname);
+ dir = dirname(tmp);
+
+ /* Creating a new file? */
+@@ -526,6 +527,7 @@ ResolveName(char *filename)
+ }
+
+ XtFree(tmp);
++ free(fname);
+ }
+
+ return (result);