[SOLVED] Just something interesting about 'system' command and daemons

view full story

http://ubuntuforums.org – I thought I would share this as it caused me to scratch my head for a while. What I wanted to do: 1. Use wget to get some XML from a rss feed. 2. Use tinyxml to parse it. 3. implement this in a daemon. Roughly this is how it worked: 1. use system("wget -O filename <url>"); 2. tinyxml loadfile(filename); This load failed every time with 'empty document' error. When I looked inside the document it contained the console output from the wget, which caused tinyxml to fail loading the document. By adding the -q option to wget, the problem went away. As a generalisatio (Hardware)