static int zlog_spec_write_us(zlog_spec_t * a_spec, zlog_thread_t * a_thread, zlog_buf_t * a_buf) { if (!a_thread->event->time_stamp.tv_sec) { gettimeofday(&(a_thread->event->time_stamp), NULL); } return zlog_buf_printf_dec32(a_buf, a_thread->event->time_stamp.tv_usec, 6); }
static int zlog_spec_write_us(zlog_spec_t * a_spec, zlog_thread_t * a_thread, zlog_buf_t * a_buf) { /* do fetch time every event once */ zlog_spec_fetch_time; return zlog_buf_printf_dec32(a_buf, a_thread->event->time_stamp.tv_usec, 6); }