added usage of conns.FLAG for exiting
Merge branch 'fix3-client-freeze'