handling TERM & INT signals