Fix ELAPSED macros in rig.c to provide more accurate timing

pull/875/head
Mike Black W9MDB 2021-11-07 07:36:46 -06:00
rodzic a9c2792c23
commit 663b149a48
1 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -157,8 +157,8 @@ const char hamlib_copyright[231] = /* hamlib 1.2 ABI specifies 231 bytes */
#define CHECK_RIG_ARG(r) (!(r) || !(r)->caps || !(r)->state.comm_state)
#define ELAPSED1 clock_t __begin = clock()
#define ELAPSED2 rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, ((double)clock() - __begin) / CLOCKS_PER_SEC * 1000)
#define ELAPSED1 struct timespec __begin; elapsed_ms(&__begin, HAMLIB_ELAPSED_SET);
#define ELAPSED2 rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, elapsed_ms(&__begin, HAMLIB_ELAPSED_GET));
#define LOCK \