diff options
| author | Garrett D'Amore <garrett@damore.org> | 2017-08-12 07:48:21 -0700 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2017-08-12 07:48:21 -0700 |
| commit | 0584aa354014e91a9036bc51bad438e8fddaf15f (patch) | |
| tree | f9aed797c71bea1302f9aa8a5a3fd7b6787b276a /src/nng_compat.c | |
| parent | ee4572147ade37bf07f8ef2f3049e8c81df312b7 (diff) | |
| download | nng-0584aa354014e91a9036bc51bad438e8fddaf15f.tar.gz nng-0584aa354014e91a9036bc51bad438e8fddaf15f.tar.bz2 nng-0584aa354014e91a9036bc51bad438e8fddaf15f.zip | |
Moved a few private test items into test-specific header.
Diffstat (limited to 'src/nng_compat.c')
| -rw-r--r-- | src/nng_compat.c | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/src/nng_compat.c b/src/nng_compat.c index 710be9be..2593a0dd 100644 --- a/src/nng_compat.c +++ b/src/nng_compat.c @@ -864,37 +864,3 @@ nn_term(void) // in a library -- only e.g. atexit() and similar. nng_closeall(); } - -// Internal test support routines. - -void -nn_sleep(uint64_t msec) -{ - nng_usleep(msec * 1000); -} - -uint64_t -nn_clock(void) -{ - return (nng_clock()); -} - -extern void nni_panic(const char *, ...); - -int -nn_thread_init(struct nn_thread *thr, void (*func)(void *), void *arg) -{ - int rv; - - rv = nng_thread_create(&thr->thr, func, arg); - if (rv != 0) { - nni_panic("Cannot create thread: %s", nng_strerror(rv)); - } - return (rv); -} - -void -nn_thread_term(struct nn_thread *thr) -{ - nng_thread_destroy(thr->thr); -} |
