| # | Line 298 | Line 298 | x11_flush() /* flush output */ | |
|---|---|---|
| 298 | n = XPending(ourdisplay); /* from X server */ | |
| 299 | while (n-- > 0) | |
| 300 | getevent(); | |
| 301 | + | #ifdef FNDELAY |
| 302 | if (inpcheck == IC_IOCTL) { /* from stdin */ | |
| 303 | + | #ifdef FIONREAD |
| 304 | if (ioctl(fileno(stdin), FIONREAD, &n) < 0) { | |
| 305 | + | #else |
| 306 | + | if (1) { |
| 307 | + | #endif |
| 308 | if (fcntl(fileno(stdin), F_SETFL, FNDELAY) < 0) { | |
| 309 | stderr_v("Cannot change input mode\n"); | |
| 310 | quit(1); | |
| # | Line 315 | Line 320 | x11_flush() /* flush output */ | |
| 320 | tocombuf(buf, &x11_driver); | |
| 321 | } | |
| 322 | } | |
| 323 | + | #endif |
| 324 | } | |
| 325 | ||
| 326 | ||
| – | Removed lines |
| + | Added lines |
| < | Changed lines (old) |
| > | Changed lines (new) |