Use buffer size #define
Free the prompt buffer
Add client/server initialization code