trace.go 817 B

123456789101112131415161718192021222324252627282930313233343536
  1. /*
  2. * Copyright (c) 2013 IBM Corp.
  3. *
  4. * All rights reserved. This program and the accompanying materials
  5. * are made available under the terms of the Eclipse Public License v1.0
  6. * which accompanies this distribution, and is available at
  7. * http://www.eclipse.org/legal/epl-v10.html
  8. *
  9. * Contributors:
  10. * Seth Hoenig
  11. * Allan Stockdill-Mander
  12. * Mike Robertson
  13. */
  14. package mqtt
  15. import (
  16. "io/ioutil"
  17. "log"
  18. )
  19. // Internal levels of library output that are initialised to not print
  20. // anything but can be overridden by programmer
  21. var (
  22. ERROR *log.Logger
  23. CRITICAL *log.Logger
  24. WARN *log.Logger
  25. DEBUG *log.Logger
  26. )
  27. func init() {
  28. ERROR = log.New(ioutil.Discard, "", 0)
  29. CRITICAL = log.New(ioutil.Discard, "", 0)
  30. WARN = log.New(ioutil.Discard, "", 0)
  31. DEBUG = log.New(ioutil.Discard, "", 0)
  32. }