dhcp: fix lease renewal for non-default fibs 43/43743/4
authorFlorin Coras <[email protected]>
Tue, 23 Sep 2025 19:32:11 +0000 (15:32 -0400)
committerFlorin Coras <[email protected]>
Tue, 23 Sep 2025 23:34:40 +0000 (19:34 -0400)
Type: fix

Change-Id: Ic6f02e47cd7f83d3ac0f273b9bff5c6c1d8d5a43
Signed-off-by: Florin Coras <[email protected]>
Signed-off-by: Steven Luong <[email protected]>
src/plugins/dhcp/client.c

index d81d293..1add8d5 100644 (file)
@@ -510,7 +510,11 @@ send_dhcp_pkt (dhcp_client_main_t * dcm, dhcp_client_t * c,
       vnet_buffer (b)->ip.adj_index[VLIB_TX] = c->ai_bcast;
     }
   else
-    node_index = dcm->ip4_lookup_node_index;
+    {
+      node_index = dcm->ip4_lookup_node_index;
+      vnet_buffer (b)->sw_if_index[VLIB_TX] =
+       fib_table_get_index_for_sw_if_index (FIB_PROTOCOL_IP4, c->sw_if_index);
+    }
 
   /* Enqueue the packet right now */
   f = vlib_get_frame_to_node (vm, node_index);