> -----Original Message----- > From: David Marchand <david.march...@redhat.com> > Sent: Wednesday, October 20, 2021 12:54 PM > To: Wang, Yipeng1 <yipeng1.w...@intel.com>; Gobriel, Sameh > <sameh.gobr...@intel.com>; Richardson, Bruce > <bruce.richard...@intel.com> > Cc: dev <dev@dpdk.org>; dpdk stable <sta...@dpdk.org>; Medvedkin, > Vladimir <vladimir.medved...@intel.com> > Subject: Re: [PATCH v3] test/hash: fix buffer overflow > > On Tue, Oct 19, 2021 at 5:58 PM Medvedkin, Vladimir > <vladimir.medved...@intel.com> wrote: > > > I am not against the fix, but it seems to test something different > > > than what an application using the hash library would do. > > > Or if an application directly calls this hash function, maybe the > > > unit test should not test it via rte_hash_create (which seems to > > > defeat the abstraction). > > > > > > > I'd say that user should not use this hash function with rte_hash. > > Yipeng, Sameh, Bruce, > > what do you think? > > Guys, can we conclude? > Thanks. > > > -- > David Marchand [Wang, Yipeng]
Vladimir, Bruce and I discussed a bit offline and I think we agreed on this fix. But we should be more clear in the comment of rte_hash_create about what hash function the API expected (I.e. key length is byte count). Acked-by: Yipeng Wang <yipeng1.w...@intel.com>