in reply to Re: Keeping a loop alive in thread Keeping a loop alive
Nope, doesn't work. As soon as tcpdump dies, the rest of it closes gracefully. Perhaps I'm overcomplicating matters, but would it help to fork() the process, then monitor the status of the child? Doesn't seem as though that would be theoretically any different than doing the "while (1)" loop.
-fp
Update: Minor correction. If I manually kill tcpdump, the loop does successfully start a new tcpdump process. It's only when I flush the states, and my ssh connection is closed, that it appears to kill off everything. I'm starting to wonder if it isn't a problem with a controlling terminal?
|