Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!cmcl2!esquire!sullivan From: sullivan@esquire.UUCP (David J. Sullivan) Newsgroups: comp.sys.pyramid Subject: tail -f stops working Keywords: tail, read, sleep, bug? Message-ID: <1290@esquire.UUCP> Date: 27 Jun 89 18:14:06 GMT Organization: DP&W, New York, NY Lines: 29 I've noticed something that is quite vexing and a bit confusing: tail -f's on files that don't change often can stop working. In essence, the code looks like: for (;;) { sleep(1); while ((n = read (0, bin, BUFSIZ)) > 0) (void)write (1, bin, n); } In fact, any sort of read on something that might not have data for quite a while -- sometimes as little as 15 minutes, but sometimes longer -- can go into the big sleep and not wake up. Bopping these programs with other signals can sometimes wake them up (bringing them to the foreground, stopping them and then backgrounding them again, for example). FYI, this is at OSx 4.1-880930 on a 98x in the ucb universe. I haven't gotten 5.0 up yet, so I can't say if it's different. Can anyone shed some light on this? Is this a bug, or what? Thanks! David J. Sullivan Davis Polk & Wardwell, 14 Wall Street, NYC 10005 212/266-0730 ARPA: sullivan@acf4.nyu.edu UUCP: {uunet|cmcl2}!esquire!sullivan