home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / unix / shell / 5344 < prev    next >
Encoding:
Text File  |  1993-01-11  |  1.4 KB  |  38 lines

  1. Newsgroups: comp.unix.shell
  2. Path: sparky!uunet!cs.utexas.edu!uwm.edu!spool.mu.edu!agate!linus!progress!bedford.progress.COM!tucker
  3. From: tucker@bedford.progress.COM (Kyle Tucker)
  4. Subject: read not reading
  5. Message-ID: <1993Jan11.210839.9498@progress.com>
  6. Sender: tucker@bahrain (Kyle Tucker)
  7. Nntp-Posting-Host: bahrain
  8. Reply-To: tucker@bedford.progress.COM
  9. Organization: Progress Software Corp.
  10. Date: Mon, 11 Jan 1993 21:08:39 GMT
  11. Lines: 25
  12.  
  13. Perhaps I'm losing it, but I swear this is what I see happening.
  14.  
  15. cat file | while read LINE
  16. do
  17.     if [ certain things are true about $LINE ]
  18.     then
  19.         do some stuff based on values in $LINE
  20.     fi
  21. done
  22.  
  23. Now, if I do "some stuff" , which is a lot of text hacking, etc, but
  24. absolutely no exits,breaks,continues,etc, the read command sees no
  25. more lines in the file. If I don't do "some stuff", then it reads next
  26. line fine. sh -x shows the read is actually occuring, but ending as
  27. if it sees EOF. Has this been seen before? This also occurs if the reads
  28. are done through standard input.
  29.  
  30. Any help/experience with this greatly appreciated!
  31.  
  32. - Kyle
  33. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  34. Kyle Tucker - Email Administrator  |         Progress Software Corporation
  35. tucker@bedford.progress.com        |        14 Oak Park
  36. (617)280-4565               |        Bedford, Mass. 01730
  37. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  38.