summaryrefslogtreecommitdiff
path: root/net/ntop1/patches/patch-ac
blob: 046203fad03627567c3a513dbd6a32ec4e53279d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
$NetBSD: patch-ac,v 1.1.1.1 2005/01/06 11:44:16 adam Exp $

--- pbuf.c.orig	Mon May  3 17:43:09 1999
+++ pbuf.c
@@ -843,20 +843,18 @@
 
 int checkKeyPressed() {
   int theChar = getch();
-  unsigned char in_char;
   int rc = 1, numScreens; 
 
-  if((theChar != EOF) 
-     && ((in_char = (unsigned char)theChar)) != 255) {
+  if((theChar != EOF) && (theChar != ERR)) {
   
     /*
       char buf[32];
 
-      sprintf(buf, ">%c-%d<", in_char, in_char);
+      sprintf(buf, ">%c-%d<", theChar, theChar);
       mvprintw(0, 40, buf); refresh();
       sleep(2);
     */
-    switch(in_char) {
+    switch(theChar) {
     case 'q':
     case 'Q':
       cleanup(-1);