|P is for Practical|
Redirect output of the system() commandby Gangabass (Priest)
|on Jul 11, 2012 at 04:04 UTC||Need Help??|
Gangabass has asked for the
wisdom of the Perl Monks concerning the following question:
I'm trying to redirect output (warnings) of some weird program to /dev/null (I don't want this info in web server's error log) but with no luck.
The program I'm talking about is wkhtmltopdf and the main problem with it that it's accept several files. So then I use ">/dev/null 2>&1" it think about /dev/null like a file to convert.
So this code gives me an error about wrong file name:
I'm also tried to enclose whole command in () and next redirect it. But this approach is not working from system().
Please help me to redirect output in this situation.