port fix of install_signal_handler from current libi2ncommon to compat code