diff options
author | John Thacker <johnthacker@gmail.com> | 2021-12-27 01:02:02 -0500 |
---|---|---|
committer | John Thacker <johnthacker@gmail.com> | 2021-12-27 01:02:02 -0500 |
commit | b1b1d2454867cf886458ae5244ae88d4a1b4640f (patch) | |
tree | 19ec6e552bbc1839b5f26c85e5985068e648962a /wsutil/inet_addr.h | |
parent | 23355cddf688c75d3241f094f12e9f5da8ef47d4 (diff) |
wsutil: Declare ws_inet_* with extern "C"
Specify C linkage for ws_inet_pton[4|6] in order to use them
from the GUI.
Diffstat (limited to 'wsutil/inet_addr.h')
-rw-r--r-- | wsutil/inet_addr.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/wsutil/inet_addr.h b/wsutil/inet_addr.h index 5bc4e7ea9f..c7f120453f 100644 --- a/wsutil/inet_addr.h +++ b/wsutil/inet_addr.h @@ -50,6 +50,10 @@ #define WS_INET_ADDRSTRLEN 16 #define WS_INET6_ADDRSTRLEN 46 +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + /* * To check for errors set errno to zero before calling ws_inet_ntop{4,6}. * ENOSPC is set if the result exceeds the given buffer size. @@ -66,4 +70,8 @@ ws_inet_pton4(const gchar *src, ws_in4_addr *dst); WS_DLL_PUBLIC gboolean ws_inet_pton6(const gchar *src, ws_in6_addr *dst); +#ifdef __cplusplus +} +#endif /* __cplusplus */ + #endif |