socket_fastopen(3)

socket_fastopen3

Enable tcp fast open on a server-side tcp socket

Usage

#include <libowfat/socket.h>

int socket_fastopen(int s);

Overview

socket_fastopen enables TCP Fast Open support on a server-side TCP socket. Call this before socket_listen(). If the platform does not support this functionality, returns -1 and sets errno to ENOPROTOOPT (or ENOSYS if the platform does not define ENOPROTOOPT).

Normally socket_fastopen returns 0. If anything goes wrong, socket_fastopen returns -1, setting errno appropriately.

Examples

#include <libowfat/socket.h>

int s;
char ip[4];
uint16 p;

s = socket_tcp4b();
socket_fastopen(s);
socket_bind4_reuse(s,ip,p);
socket_listen(16);

Releases

5 releases since Debian 9 (Stretch); the text changed 1 time.

  1. 9–11
  2. 12–13

From libowfat-dev 0.32-5 in Debian 13 (Trixie). Parsed by carta from the page's man source.