hello, I have come across some problems with cygwin (they repeat even with the latest cygwin i installed two days back) while working on windows 2000.
cygwin1.dll Product Version is 1.3.22-dontuse-21 bash --version shows GNU bash, version 2.05b.0(9)-release (i686-pc-cygwin) Copyright (C) 2002 Free Software Foundation, Inc. The problems are -- [1] for i in list-of-file-name do echo ............. $i ................ cat $i done Sometimes the order of echoed statement and corresponding file content gets changed and I end up getting output like .............. file20 ...................... .............. file21 ...................... .............. file22 ...................... contents of file20 contents of file21 contents of file22 [2] following problem is more weird . I have a sequence of two consecutive statements in a bash-script sed -e 'sed-expression' file1 > file2 mv file2 file1 quite many times in a run of script 'mv' cribs about *file2 not existing* my understanding of bash goes as -- file2 will be created/zeroed-out first and then sed will be processed, so file2 should exist before mv executes. as a note :- file2 doesn't exist before sed (manipulations involving file2 are only in this place in script) I also tried putting an && b/w two statements to ensure 'mv' doesn't happen before sed is successfully done. that also didn't eliminate the problem. [3] At times some of the echo-ed statements don't find place in redirected output file (I have no idea if this behaviour repeats on console output too). situation is like -- cp basefile tempfile add-required-statements >> tempfile add-required-statements is a bash shell function that echoes many statements to be put in tempfile. what i have observed is - at times, initial 3-4 echo-ed statements don't find place in tempfile, otherwise things are okay. problem used to come even earlier, when all those statements were appended like -- cp basefile tempfile echo "......" >> tempfile ........ echo "...." >> tempfile i went for some reorganisation of script to reduce number of ">> tempfile" checking if it eliminated the problem. Any clue to what's happening and why it could be happening, is welcome. Are these problems to do with cygwin bash or with windows 2000? sandeep --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.507 / Virus Database: 304 - Release Date: 8/4/2003 -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/