A free boundary problem connected with the optimal stopping problem for diffusion processes