diff options
| author | Garrett D'Amore <garrett@damore.org> | 2016-12-24 15:08:24 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2016-12-24 15:08:24 -0800 |
| commit | cb4fe7294f7da2ad1a2fdf896748b42e1a8115ab (patch) | |
| tree | 1718afad8387d2dbcebb771d804fb7b5cf4d700b /src/nng.c | |
| parent | 9ff00f18a38559f668cb5c27e6d814dddffa801d (diff) | |
| download | nng-cb4fe7294f7da2ad1a2fdf896748b42e1a8115ab.tar.gz nng-cb4fe7294f7da2ad1a2fdf896748b42e1a8115ab.tar.bz2 nng-cb4fe7294f7da2ad1a2fdf896748b42e1a8115ab.zip | |
Getopt implemented (and minimal test).
Diffstat (limited to 'src/nng.c')
| -rw-r--r-- | src/nng.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -83,6 +83,18 @@ nng_setopt(nng_socket *s, int opt, const void *val, size_t sz) } +int +nng_getopt(nng_socket *s, int opt, void *val, size_t *szp) +{ + int rv; + + if ((rv == nni_init()) != 0) { + return (rv); + } + return (nni_socket_getopt(s, opt, val, szp)); +} + + // Misc. const char * nng_strerror(int num) |
