mirror of
https://github.com/open-telemetry/opentelemetry-go.git
synced 2024-12-04 09:43:23 +02:00
Unslice to simplify (#324)
This commit is contained in:
parent
90ba74e15a
commit
eb3b31e12d
@ -135,7 +135,7 @@ func decodeHex(h string, b []byte) error {
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
copy(b[:], decoded)
|
copy(b, decoded)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -126,7 +126,7 @@ func (hp HTTPTraceContextPropagator) extractSpanContext(
|
|||||||
if len(sections[2]) != 16 {
|
if len(sections[2]) != 16 {
|
||||||
return core.EmptySpanContext()
|
return core.EmptySpanContext()
|
||||||
}
|
}
|
||||||
sc.SpanID, err = core.SpanIDFromHex(sections[2][:])
|
sc.SpanID, err = core.SpanIDFromHex(sections[2])
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return core.EmptySpanContext()
|
return core.EmptySpanContext()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user