Signal handle for foreground

Fluentd's code of HEAD doesn't take care for situations executed as foreground process.

For foreground process, terminals and daemonize tools send signals to all processes in target process group. In result, Fluent::Engine.stop will be called twice and invalid shutdown processes will be executed.

This patch cannot solve problems about out_exec_filter completely.
Child processes of out_exec_filter will exit with signals for process group, and out_exec_filter cannot make proper dicision to ignore exiting child process or not.