openbsd-ports/news/trn/patches/patch-term_c
espie 122e95316f make trn work on sparc64: FIONREAD fills an int on OpenBSD.
Add various missing prototypes while we're at it.
2005-05-29 14:19:08 +00:00

16 lines
395 B
Plaintext

$OpenBSD: patch-term_c,v 1.1 2005/05/29 14:19:08 espie Exp $
--- term.c.orig Sun May 29 16:12:29 2005
+++ term.c Sun May 29 16:13:00 2005
@@ -662,9 +662,9 @@ bool_int check_term;
#endif
if (check_term) {
# ifdef FIONREAD
- long iocount;
+ int iocount;
ioctl(0, FIONREAD, &iocount);
- return (int)iocount;
+ return iocount;
# else /* !FIONREAD */
# ifdef HAS_RDCHK
return rdchk(0);