Re: device list reversed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Sun, Apr 11, 2021 at 03:07:41PM +0200, Frank Wunderlich wrote:
> Hi,
> 
> i import ruleset by file with a devicelist (flowtable)
> 
> devices = { wan, lan0, lan3 }
> 
> and if i do a nft list ruleset, it gets reversed
> 
> devices = { lan3, lan0, wan }
> 
> imho this is a cosmetic thing, but strange anyway
> 
> took a look in ./libnftnl/src/flowtable.c but it seems the loop is always done in forward way
> 
> any idea why this happen?

Each device is represented as a hook, and hook are registered using
list_add() IIRC, which is reversing the order.

Probably just sort device names alphanumerically?



[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux