aboutsummaryrefslogtreecommitdiff
path: root/util/trace_logging.h
diff options
context:
space:
mode:
authorRyan Keane <rwkeane@google.com>2020-05-07 13:36:29 -0700
committerCommit Bot <commit-bot@chromium.org>2020-05-07 21:20:56 +0000
commitb766238da67fe1892e8e0c4de920d072521f7405 (patch)
tree55c47adb962d74962259c06275689025af962b0a /util/trace_logging.h
parenta44d04ae66815d117c864a137db5674e6a3f3f32 (diff)
downloadopenscreen-b766238da67fe1892e8e0c4de920d072521f7405.tar.gz
Discovery: Add Trace Logging
Adds trace logging to the DNS-SD layer so that multiple calls with error codes can all be traced if multiple failures occur. Bug: b/155337599 Change-Id: Ic5ba146cf467895092ee6655213097bb0cf2fef2 Reviewed-on: https://chromium-review.googlesource.com/c/openscreen/+/2182319 Commit-Queue: Ryan Keane <rwkeane@google.com> Reviewed-by: Jordan Bayles <jophba@chromium.org>
Diffstat (limited to 'util/trace_logging.h')
-rw-r--r--util/trace_logging.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/util/trace_logging.h b/util/trace_logging.h
index 84732be2..0384ab70 100644
--- a/util/trace_logging.h
+++ b/util/trace_logging.h
@@ -82,6 +82,8 @@ inline void DoNothingForTracing(Args... args) {}
#define TRACE_ROOT_ID openscreen::kEmptyTraceId
#define TRACE_SCOPED(category, name, ...) \
openscreen::internal::DoNothingForTracing(category, name, ##__VA_ARGS__)
+#define TRACE_DEFAULT_SCOPED(category, ...) \
+ TRACE_SCOPED(category, __PRETTY_FUNCTION__, ##__VA_ARGS__)
#define TRACE_ASYNC_START(category, name, ...) \
openscreen::internal::DoNothingForTracing(category, name, ##__VA_ARGS__)
#define TRACE_ASYNC_END(category, id, result) \