From: Dave H. <dhy...@gm...> - 2007-03-16 00:23:50
|
Hi Chris, On 3/15/07, Chris Parker <par...@ie...> wrote: > Hey all. I was testing a serial i/o program that I am writing > today, and I killed it with a control-C. The next time I went to run > it, I got the error "Bad file descriptor" when I tried to write to > ttyS2 (I was able to open a file descriptor for ttyS2, though...). > Rebooting the gumstix made no difference. I should point out that I > was being stupid and running my code as root. How should I fix > this? There is the brute-force solution of reflashing the > filesystem, but I would prefer a more elegant solution, if there is one. Was your open successful? Or did it return a negative number? Can you post your code? Sorry to say it, but "bad file descriptor" sounds like a bug in your code :) -- Dave Hylands Vancouver, BC, Canada http://www.DaveHylands.com/ |