Reading the thread, I was also going to suggest this possibility, if ikegami had not done it before, because I had the same problem a couple of months ago and it took me at least 30 minutes to figure out that the line that appeared not to be printed was in fact overwritten by the next line (data produced on Windows and used on a Unix box, so that chomp removed the \n but not the \r).