0

I am trying to code server - client to transfer file.

My problem is when I use file with small size. It's Ok, but when I use bigger size, it has:

"Connection reset by peer: socket write error".

enter image description here

J. Scott Elblein
  • 4,013
  • 15
  • 58
  • 94
  • 1
    Please do not add code as image. Add it as text instead. Have a look [here](https://stackoverflow.com/editing-help#code) on how to add code to your question. – MrToast Jun 22 '20 at 06:54
  • You haven't posted the peer code but it is clearly in error. As is this code. You can't assume that `read()` fills the buffer. That's why it returns a count. – user207421 Jun 22 '20 at 10:13

0 Answers0