aboutsummaryrefslogtreecommitdiff
path: root/src/supplemental/http/http_api.h
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2018-05-05 11:03:33 -0700
committerGarrett D'Amore <garrett@damore.org>2018-05-06 15:21:33 -0700
commit916ba1ab23aa50b855fd795f095eaedb328e84d9 (patch)
treeb764e37145e7caf8f2fe7d1a3999ab6798c3a095 /src/supplemental/http/http_api.h
parent7ecb0e4a74bbb3d49ebe37a14b2534a242cb930a (diff)
downloadnng-916ba1ab23aa50b855fd795f095eaedb328e84d9.tar.gz
nng-916ba1ab23aa50b855fd795f095eaedb328e84d9.tar.bz2
nng-916ba1ab23aa50b855fd795f095eaedb328e84d9.zip
fixes #396 illumos doesn't build (missing NNG_PLATFORM_POSIX ON)
fixes #397 Need to cast zoneid fixes #395 sun is predefined on illumos/Solaris fixes #394 alloca needs to #include <alloca.h> fixes #399 Cannot use SVR4.2 specific msghdr fixes #402 getpeerucred needs a NULL initialized ucred fixes #403 syntax error in posix_tcp - attempt to return void fixes #407 illumos getegid wrong fixes #406 nni_idhash_count is dead code fixes #404 idhash typedef redeclared fixes #405 warning: newline not last character in file This is basically a slew of related bug fixes required to make this work on illumos. Note that the fixes are not "complete", because more work is required to support port events given that epoll is busted on illumos. We also fixed a bunch of things that aren't actually "bugs" per se, but really just warnings. Silencing them makes things better for everyone. Apparently not all compilers are equally happy with redundant (but otherwise identical) typedefs; we use structs in some places instead of shorter type names to silence these complaints. Note that IPC permissions (the mode bits on the socket vnode) are not validated on SunOS systems. This change includes documentation to reflect that.
Diffstat (limited to 'src/supplemental/http/http_api.h')
-rw-r--r--src/supplemental/http/http_api.h13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/supplemental/http/http_api.h b/src/supplemental/http/http_api.h
index 8de859b4..f1a5c0fa 100644
--- a/src/supplemental/http/http_api.h
+++ b/src/supplemental/http/http_api.h
@@ -65,7 +65,8 @@ extern void *nni_http_conn_get_ctx(nni_http_conn *);
// They should only be used by the server or client HTTP implementations,
// and are not for use by other code.
extern int nni_http_conn_init_tcp(nni_http_conn **, void *);
-extern int nni_http_conn_init_tls(nni_http_conn **, nng_tls_config *, void *);
+extern int nni_http_conn_init_tls(
+ nni_http_conn **, struct nng_tls_config *, void *);
extern void nni_http_conn_close(nni_http_conn *);
extern void nni_http_conn_fini(nni_http_conn *);
@@ -153,12 +154,13 @@ extern int nni_http_server_del_handler(nni_http_server *, nni_http_handler *);
// server client, so the caller must have configured it reasonably.
// This API is not recommended unless the caller needs complete control
// over the TLS configuration.
-extern int nni_http_server_set_tls(nni_http_server *, nng_tls_config *);
+extern int nni_http_server_set_tls(nni_http_server *, struct nng_tls_config *);
// nni_http_server_get_tls obtains the TLS configuration if one is present,
// or returns NNG_EINVAL. The TLS configuration is invalidated if the
// nni_http_server_set_tls function is called, so be careful.
-extern int nni_http_server_get_tls(nni_http_server *, nng_tls_config **);
+extern int nni_http_server_get_tls(
+ nni_http_server *, struct nng_tls_config **);
// nni_http_server_start starts listening on the supplied port.
extern int nni_http_server_start(nni_http_server *);
@@ -273,12 +275,13 @@ extern void nni_http_client_fini(nni_http_client *);
// the entire TLS configuration on the client, so the caller must have
// configured it reasonably. This API is not recommended unless the
// caller needs complete control over the TLS configuration.
-extern int nni_http_client_set_tls(nni_http_client *, nng_tls_config *);
+extern int nni_http_client_set_tls(nni_http_client *, struct nng_tls_config *);
// nni_http_client_get_tls obtains the TLS configuration if one is present,
// or returns NNG_EINVAL. The supplied TLS configuration object may
// be invalidated by any future calls to nni_http_client_set_tls.
-extern int nni_http_client_get_tls(nni_http_client *, nng_tls_config **);
+extern int nni_http_client_get_tls(
+ nni_http_client *, struct nng_tls_config **);
extern void nni_http_client_connect(nni_http_client *, nni_aio *);