aboutsummaryrefslogtreecommitdiffstats
path: root/editors/xvile
diff options
context:
space:
mode:
authorgj <gj@FreeBSD.org>2010-01-01 16:48:09 +0800
committergj <gj@FreeBSD.org>2010-01-01 16:48:09 +0800
commit7b3be53e32ddd0cab73d458feec4c80869644c3b (patch)
tree0c82a4aaf06dd5218d8212ca2b0fa1d40e5711bc /editors/xvile
parentd3705dcad633077474fe570b8ea2872493e54238 (diff)
downloadfreebsd-ports-gnome-7b3be53e32ddd0cab73d458feec4c80869644c3b.tar.gz
freebsd-ports-gnome-7b3be53e32ddd0cab73d458feec4c80869644c3b.tar.zst
freebsd-ports-gnome-7b3be53e32ddd0cab73d458feec4c80869644c3b.zip
Add patch-x11.c to prevent a core dump in case the user has "set rc light"
in .vilerc. Bump PORTREVISION to reflect this change.
Diffstat (limited to 'editors/xvile')
-rw-r--r--editors/xvile/Makefile1
-rw-r--r--editors/xvile/files/patch-x11.c21
2 files changed, 22 insertions, 0 deletions
diff --git a/editors/xvile/Makefile b/editors/xvile/Makefile
index dc9fb45a34de..9e36faf87e60 100644
--- a/editors/xvile/Makefile
+++ b/editors/xvile/Makefile
@@ -7,6 +7,7 @@
PORTNAME= xvile
PORTVERSION= 9.7y
+PORTREVISION= 1
CATEGORIES= editors
MASTER_SITES= ftp://invisible-island.net/vile/ \
ftp://dickey.his.com/vile/ \
diff --git a/editors/xvile/files/patch-x11.c b/editors/xvile/files/patch-x11.c
new file mode 100644
index 000000000000..260f846ba038
--- /dev/null
+++ b/editors/xvile/files/patch-x11.c
@@ -0,0 +1,21 @@
+--- x11.c.orig 2009-12-31 14:32:20.000000000 +0100
++++ x11.c 2009-12-31 14:33:53.000000000 +0100
+@@ -2180,10 +2180,15 @@
+ static GC
+ get_color_gc(int n, Boolean normal)
+ {
+- ColorGC *data = (normal
+- ? &(cur_win->fore_color[n])
+- : &(cur_win->back_color[n]));
++ ColorGC *data;
+
++ assert(n >= 0 && n < NCOLORS);
++
++ if (n < 0 || n > NCOLORS)
++ n = 0; /* shouldn't happen */
++ data = (normal
++ ? &(cur_win->fore_color[n])
++ : &(cur_win->back_color[n]));
+ if (cur_win->screen_depth == 1) {
+ data->gc = (normal
+ ? cur_win->textgc