By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,492 Members | 3,174 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,492 IT Pros & Developers. It's quick & easy.

windows socket error 10054

P: 22
i have a client,server application... I have made the server to listen and accept a connection. The client also connects successfully

The connection works good except that i get the WSAECONNRESET error at times.

server works as


after server's send, the server's recv(supposed to block)
fails with the error 10054

It does not happen when small amount of data is sent..

What could be the cause of the problem,
Is there any restriction in size of data to be sent via a windows socket?

p.s- There is no loss of connection between client and server (run on the same machine)
Jan 22 '09 #1
Share this Question
Share on Google+
3 Replies

Expert Mod 5K+
P: 8,916
WSAECONNRESET is tied into how the connection to the server is set-up but you have not shown logically where you are doing the connection.

If you drop a connection and then try to re-establish it too quickly you can get this error.
Jan 22 '09 #2

P: 22
server has this code

// Connection is made here

After send() , the subsequent recv() fails. with error 10054
Though the send() call was successful client does not receive it.

This happens after 2 or 3 interactions with the server

The first interactions happen perfectly.

I have not disconnected or closed the socket anywhere...
Jan 22 '09 #3

P: 22
Since i forgot to free() memory allocated the server made a heap error, which failed the server and caused the message...

Thanks everyone for ur valuable effort...
Jan 23 '09 #4

Post your reply

Sign in to post your reply or Sign up for a free account.