Re: OT: bash script - unexpected exit

2012-01-17 Thread Matthew Mosesohn
Sorry about that. I meant to say that using for line in $(cat file) is bad because it might not split up into lines properly. - Original Message - From: "JD" To: "Community support for Fedora users" Sent: Monday, January 16, 2012 3:34:37 PM Subject: Re: OT: bash script - unexpecte

Re: OT: bash script - unexpected exit

2012-01-16 Thread Matthew Mosesohn
You shouldn't rely on cat or for to read a file line by line, but instead do this: while read line; do commands done < hosts Matthew Mosesohn "Мир тесен." - Original Message - From: "Hiisi" To: "Community support for Fedora users" Sent