perror("bind");
exit(1);
}
+
+ int buf = 10 << 20; // 20 MB.
+ if (setsockopt(sock, SOL_SOCKET, SO_RCVBUF, &buf, sizeof(buf)) == -1) {
+ perror("setsockopt(SO_RCVBUF)");
+ exit(1);
+ }
}
void GREProtocol::send_packet(uint16_t proto, const string &data, int incoming_seq)