mptcpd
Multipath TCP Daemon
Loading...
Searching...
No Matches
Macros | Functions
mptcpize.c File Reference

enable mptcp on existing services. More...

#include <linux/limits.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/sendfile.h>
#include <argp.h>
#include <dlfcn.h>
#include <errno.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
Include dependency graph for mptcpize.c:

Macros

#define _GNU_SOURCE
 
#define SYSTEMD_ENV_VAR   "Environment="
 
#define SYSTEMD_UNIT_VAR   "FragmentPath="
 
#define SYSTEMD_SERVICE_TAG   "[Service]"
 
#define SYSTEMCTL_SHOW   "systemctl show -p FragmentPath "
 
#define PRELOAD_VAR   "LD_PRELOAD="
 
#define MPTCPWRAP_ENV   PKGLIBDIR"/libmptcpwrap.so.0.0."LIBREVISION
 
#define GODEBUG_VAR   "GODEBUG="
 
#define MPTCPGO_ENV   "multipathtcp=1"
 
#define ERROR_HELPER(status, errnum, format, ...)
 
#define error(...)   ERROR_HELPER(__VA_ARGS__, "\n")
 

Functions

int main (int argc, char *argv[])
 

Detailed Description

enable mptcp on existing services.

Copyright (c) 2021, Red Hat, Inc.

Macro Definition Documentation

◆ ERROR_HELPER

#define ERROR_HELPER (   status,
  errnum,
  format,
  ... 
)
Value:
do { \
if (errnum) { \
errno = errnum; \
perror(format); \
} else { \
fprintf(stderr, format "%s", __VA_ARGS__); \
} \
if (status) \
exit(status); \
} while(0)