send recv bugs fixed