Rework locking and state management of NTCP connections
	trac ticket #972
	up version to -4
Update unit test