Adding changes to send() to fix the capability of sending space.