Remove 'make check'compiler warnings
Code cleanup for redirect_output_signal()

Also fixes a compiler warning for 'make check'.