File tree Expand file tree Collapse file tree 2 files changed +4
-11
lines changed
tracing-subscriber/src/registry Expand file tree Collapse file tree 2 files changed +4
-11
lines changed Original file line number Diff line number Diff line change @@ -288,21 +288,15 @@ impl Subscriber for Registry {
288288 fn event ( & self , _: & Event < ' _ > ) { }
289289
290290 fn enter ( & self , id : & span:: Id ) {
291- if self
292- . current_spans
291+ self . current_spans
293292 . get_or_default ( )
294293 . borrow_mut ( )
295- . push ( id. clone ( ) )
296- {
297- self . clone_span ( id) ;
298- }
294+ . push ( id. clone ( ) ) ;
299295 }
300296
301297 fn exit ( & self , id : & span:: Id ) {
302298 if let Some ( spans) = self . current_spans . get ( ) {
303- if spans. borrow_mut ( ) . pop ( id) {
304- self . try_close ( id. clone ( ) ) ;
305- }
299+ spans. borrow_mut ( ) . pop ( id) ;
306300 }
307301 }
308302
Original file line number Diff line number Diff line change @@ -18,10 +18,9 @@ pub(crate) struct SpanStack {
1818
1919impl SpanStack {
2020 #[ inline]
21- pub ( super ) fn push ( & mut self , id : Id ) -> bool {
21+ pub ( super ) fn push ( & mut self , id : Id ) {
2222 let duplicate = self . stack . iter ( ) . any ( |i| i. id == id) ;
2323 self . stack . push ( ContextId { id, duplicate } ) ;
24- !duplicate
2524 }
2625
2726 #[ inline]
You can’t perform that action at this time.
0 commit comments