added listen() interrupting functionality