Re: [nft PATCH 4/5] json: Fix memleaks in echo support

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

 



On Thu, Feb 28, 2019 at 11:30:26AM +0100, Phil Sutter wrote:
> On Wed, Feb 27, 2019 at 11:29:26PM +0100, Pablo Neira Ayuso wrote:
> [...]
> > Not related to this patch: IIRC this echo support is not using the
> > nlmsg_seq to correlate the command and the result that we obtain,
> > right? Telling this because this should work with a batch that
> > contains several requests to create rules, then use this sequence
> > number to correlate things the reply with the original rule creation
> > command.
> 
> I think you once suggested that and I promised to look into it. :)
> 
> So I just did and while nlmsg_seq would serve nice to clearly identify
> which command a returned handle belongs to, I don't know how to map the
> command back to the JSON object from which it was created.

If you have a structure that stores commands in a list or such, the
idea would be to store the sequence number in the command object.
You can just keep this in the radar, no need to work on this right now.

Thanks!



[Index of Archives]     [Netfitler Users]     [Berkeley Packet Filter]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux