Don't repeatedly register cache callbacks in pgoutput plugin.
[pgsql.git] / src / include / common / ip.h
blobad7208673dd2fec0130a871c1c19f14dc79dcb56
1 /*-------------------------------------------------------------------------
3 * ip.h
4 * Definitions for IPv6-aware network access.
6 * These definitions are used by both frontend and backend code.
8 * Copyright (c) 2003-2019, PostgreSQL Global Development Group
10 * src/include/common/ip.h
12 *-------------------------------------------------------------------------
14 #ifndef IP_H
15 #define IP_H
17 #include "getaddrinfo.h" /* pgrminclude ignore */
18 #include "libpq/pqcomm.h" /* pgrminclude ignore */
21 #ifdef HAVE_UNIX_SOCKETS
22 #define IS_AF_UNIX(fam) ((fam) == AF_UNIX)
23 #else
24 #define IS_AF_UNIX(fam) (0)
25 #endif
27 extern int pg_getaddrinfo_all(const char *hostname, const char *servname,
28 const struct addrinfo *hintp,
29 struct addrinfo **result);
30 extern void pg_freeaddrinfo_all(int hint_ai_family, struct addrinfo *ai);
32 extern int pg_getnameinfo_all(const struct sockaddr_storage *addr, int salen,
33 char *node, int nodelen,
34 char *service, int servicelen,
35 int flags);
37 #endif /* IP_H */