Kill properly the process