Skip to content

Commit

Permalink
tracer workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
Tianlin-Zhao committed Jul 29, 2020
1 parent cc9b625 commit 8a38571
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/include/opentelemetry/trace/default_span.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,7 @@ class DefaultSpan: public Span {
DefaultSpan(const DefaultSpan& spn) : span_context_(spn.GetContext()) {}

trace::Tracer &tracer() const noexcept {
const trace::Tracer tracer = trace::Tracer();
return tracer; // Invalid tracer
return tracer_; // Invalid tracer
}

// Creates an instance of this class with spancontext.
Expand All @@ -79,6 +78,7 @@ class DefaultSpan: public Span {

private:
SpanContext span_context_;
trace::Tracer tracer_;
};
}
OPENTELEMETRY_END_NAMESPACE

0 comments on commit 8a38571

Please sign in to comment.