I am working with WinSock , i need to send a 2D char array. for example
char SendBuf[10][1024];
for (int i = 0; i < 10; i++){
fgets(SendBuf[i], sizeof(SendBuf), stdin);
}
and than casted it to (char*).
iResult = sendto(SendSocket, (char*)SendBuf, BufLen, 0, (SOCKADDR *)& RecvAddr, sizeof(RecvAddr));
Everything works. But on the server side i am just getting only the value of Sendbuf[0][1024], what should i do to read whole buffer.
Should work with:
and note that string N will be at location RecBuf[N*1024]