You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
388 B

  1. #include "zoslogger.hpp"
  2. #include <stdarg.h>
  3. #include <stdio.h>
  4. #include <stdlib.h>
  5. #include <string.h>
  6. iflytop::zmutex glog_mutex;
  7. extern "C" {
  8. void zos_loggger_init() { glog_mutex.init(); }
  9. void zos_log(const char* fmt, ...) {
  10. iflytop::zlock_guard lock(glog_mutex);
  11. if (g_enable_log) {
  12. va_list args;
  13. va_start(args, fmt);
  14. vprintf(fmt, args);
  15. va_end(args);
  16. }
  17. }
  18. }