some improvements in signaling code