On Tue, 2023-08-22 at 13:39 +0200, Thomas Haller wrote: > On Tue, 2023-08-22 at 10:54 +0200, Pablo Neira Ayuso wrote: > > > nftables calls localtime_r() from print/parse functions. Presumably, > we > will print/parse several timestamps during a larger operation, it > would > be odd to change/reload the timezone in between or to meaningfully > support that. > > > I think it is all good, nothing to change. Just to be aware of. > Thinking some more, the "problem" is that when we parse a larger data, then multiple subfields are parsed. Thereby we call "time()" and "localtime()" multiple times. The time() keeps ticking, and time and tz can be reset at any moment -- so we see different time/tz, in the middle of parsing the larger set of data. What IMO should happen, is that for one parse operation, we call such operations at most once, and cache them in `struct netlink_parse_ctx`. Is that considered a problem to be solved? Seems simple. Would you accept a patch for that? Thomas