diff options
| author | Garrett D'Amore <garrett@damore.org> | 2020-11-15 17:47:54 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2020-11-15 17:47:54 -0800 |
| commit | 249932f3a208260f6b9c99d778b22d51cfabe87b (patch) | |
| tree | 4fd4826127e9c225d5232c39d4ae1db89b539689 /src/platform/windows/win_tcpdial.c | |
| parent | eb328da56c3fc7167b536dcb206df0abb0f4a9b9 (diff) | |
| download | nng-249932f3a208260f6b9c99d778b22d51cfabe87b.tar.gz nng-249932f3a208260f6b9c99d778b22d51cfabe87b.tar.bz2 nng-249932f3a208260f6b9c99d778b22d51cfabe87b.zip | |
fixes #1071 tran_chkopt can be cleaned up
This is a sweeping cleanup of the transport logic around options,
and also harmonizes the names used when setting or getting options.
Additionally, legacy methods are now moved into a separate file and
can be elided via CMake or a preprocessor define.
Fundamentally, the ability to set to transport options via the socket
is deprecated; there are numerous problems with this and my earlier
approaches to deal with this have been somewhat misguided. Further
these approaches will not work with future protocol work that is
planned (were some options need to be negotiated with peers at the
time of connection establishment.)
Documentation has been updated to reflect this. The test suites still
make rather broad use of the older APIs, and will be converted later.
Diffstat (limited to 'src/platform/windows/win_tcpdial.c')
| -rw-r--r-- | src/platform/windows/win_tcpdial.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/platform/windows/win_tcpdial.c b/src/platform/windows/win_tcpdial.c index 89c5bf6a..12ebdca6 100644 --- a/src/platform/windows/win_tcpdial.c +++ b/src/platform/windows/win_tcpdial.c @@ -1,5 +1,5 @@ // -// Copyright 2019 Staysail Systems, Inc. <info@staysail.tech> +// Copyright 2020 Staysail Systems, Inc. <info@staysail.tech> // Copyright 2018 Capitar IT Group BV <info@capitar.com> // Copyright 2018 Devolutions <info@devolutions.net> // @@ -397,14 +397,14 @@ static const nni_option tcp_dialer_options[] = { }; int -nni_tcp_dialer_getopt( +nni_tcp_dialer_get( nni_tcp_dialer *d, const char *name, void *buf, size_t *szp, nni_type t) { return (nni_getopt(tcp_dialer_options, name, d, buf, szp, t)); } int -nni_tcp_dialer_setopt(nni_tcp_dialer *d, const char *name, const void *buf, +nni_tcp_dialer_set(nni_tcp_dialer *d, const char *name, const void *buf, size_t sz, nni_type t) { return (nni_setopt(tcp_dialer_options, name, d, buf, sz, t)); |
