@@ -87,7 +87,7 @@ pub struct RoutingHandler {
8787 flood_counter : u64 ,
8888 controller_send : Sender < Box < dyn Event > > ,
8989 buffer : Buffer ,
90- node_type : NodeType
90+ node_type : NodeType ,
9191}
9292
9393impl RoutingHandler {
@@ -107,7 +107,7 @@ impl RoutingHandler {
107107 flood_seen : HashSet :: new ( ) ,
108108 controller_send,
109109 buffer : Buffer :: new ( ) ,
110- node_type
110+ node_type,
111111 }
112112 }
113113
@@ -137,7 +137,11 @@ impl RoutingHandler {
137137 let packet = Packet :: new_flood_request (
138138 SourceRoutingHeader :: empty_route ( ) ,
139139 self . session_counter ,
140- FloodRequest :: new ( self . flood_counter , self . id ) ,
140+ FloodRequest {
141+ flood_id : self . flood_counter ,
142+ initiator_id : self . id ,
143+ path_trace : vec ! [ ( self . id, self . node_type) ] ,
144+ } ,
141145 ) ;
142146 self . controller_send
143147 . send ( Box :: new ( NodeEvent :: FloodStarted (
@@ -415,14 +419,15 @@ impl RoutingHandler {
415419 Fragment :: new ( i as u64 , total_n_fragments, Self :: pad_chunk ( chunk) ) ;
416420 let packet = Packet :: new_fragment ( shr. clone ( ) , session_id, fragment) ;
417421 self . try_send ( packet) ?;
418-
419422 }
420-
421- self . controller_send . send ( Box :: new ( NodeEvent :: MessageSent {
422- notification_from : self . id ,
423- to : destination,
424- } ) ) . map_err ( |_e| NetworkError :: ControllerDisconnected ) ?;
425-
423+
424+ self . controller_send
425+ . send ( Box :: new ( NodeEvent :: MessageSent {
426+ notification_from : self . id ,
427+ to : destination,
428+ } ) )
429+ . map_err ( |_e| NetworkError :: ControllerDisconnected ) ?;
430+
426431 return Ok ( ( ) ) ;
427432 }
428433
0 commit comments