Preparing the code for the signal handling part