C   77

socket c

Guest on 20th July 2022 07:11:58 AM

  1. #include <netinet/in.h>  /* IPPROTO_TCP */
  2. #include <netinet/tcp.h> /* TCP_QUICKACK */
  3. #include <stdio.h>
  4. #include <string.h>
  5. #include <sys/socket.h>
  6. #include <sys/types.h>
  7.  
  8. int main() {
  9.   int serveSockFd = socket(AF_INET, SOCK_STREAM, 0);
  10.   int optval = 1;
  11.   setsockopt(serveSockFd, IPPROTO_TCP, TCP_QUICKACK, &optval, sizeof(int));
  12.  
  13.   return 0;
  14. }

Raw Paste


Login or Register to edit or fork this paste. It's free.