I am still stuck so I am trying to do other stuff and come later on that.
The only thing that I have found is that my error seem to come from the functions write() that I use with my client but when I look other exemple they have done the same write() as me and I don’t see any change if at the end I put \r\n or \n I have the same resuts.