summaryrefslogtreecommitdiff
path: root/chat/bitchx/patches
diff options
context:
space:
mode:
authorblymn <blymn@pkgsrc.org>2001-09-30 13:52:57 +0000
committerblymn <blymn@pkgsrc.org>2001-09-30 13:52:57 +0000
commitc5a960ec80cdcf20789941059ad784d9c28b4b2d (patch)
treeece3d463f44c11ad3fedf57b219f971ebe05b098 /chat/bitchx/patches
parent1bebacda6c996c5f7d6e199e4d1b06cb7a40c40f (diff)
downloadpkgsrc-c5a960ec80cdcf20789941059ad784d9c28b4b2d.tar.gz
Fixed improper tgetstr call that was causing bitchx to crash when
used with NetBSD curses.
Diffstat (limited to 'chat/bitchx/patches')
-rw-r--r--chat/bitchx/patches/patch-ac38
1 files changed, 38 insertions, 0 deletions
diff --git a/chat/bitchx/patches/patch-ac b/chat/bitchx/patches/patch-ac
new file mode 100644
index 00000000000..9c00ae54e62
--- /dev/null
+++ b/chat/bitchx/patches/patch-ac
@@ -0,0 +1,38 @@
+$NetBSD: patch-ac,v 1.3 2001/09/30 13:52:58 blymn Exp $
+
+--- source/term.c.orig Mon Jan 8 16:54:22 2001
++++ source/term.c
+@@ -819,14 +819,14 @@
+ #ifndef WTERM_C
+ int i;
+ int desired;
+-
++ char *t2ptr;
+
+ #if !defined(__EMX__) && !defined(WINNT) && !defined(GUI)
+ memset(current_term, 0, sizeof(struct term_struct));
+
+ if (dumb_mode)
+ ircpanic("term_init called in dumb_mode");
+- *termcap2 = 0;
++ t2ptr = termcap2;
+ if (!term && !(term = getenv("TERM")))
+ {
+ fprintf(stderr, "\n");
+@@ -873,11 +873,15 @@
+ }
+ else
+ {
+- cval = Tgetstr(tcaps[i], termcap2);
++ cval = Tgetstr(tcaps[i], t2ptr);
++#ifdef HAVE_TERMINFO
+ if (cval == (char *) -1)
+ *(char **)tcaps[i].ptr = NULL;
+ else
+ *(char **)tcaps[i].ptr = cval;
++#else
++ *(char **)tcaps[i].ptr = cval;
++#endif
+ }
+ }
+