Ensure that the keyboard monitor program exit handler is only added once. (dm)