Re: [PATCH v4] test-lib-functions: use test-tool for [de]packetize()

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

 



On Fri, Jul 16, 2021 at 05:41:33PM +0200, Ævar Arnfjörð Bjarmason wrote:

> I ejected changing/adding test code for this v4. This keeps the
> compatibility wrappers and just narrowly changes the things that need
> a packetize_raw() to use that new helper.
> 
> I left the simpler packetize() case as a "printf", it could also use
> the test tool, but in case someone cares about process overhead on say
> Windows this entire change should be strictly better than the status
> quo.

This looks fine to me. I actually did like some of the readability
improvements possible in the other patches, but they can still be easily
built on top if we care to.

Using "test-tool pkt-line unpack" doesn't behave exactly like
depacketize:

  - as noted earlier, it drops stuff after a NUL

  - it says "0000" instead of "FLUSH"

But we don't seem to depend on either of those in any tests, so it's a
good time to switch. :)

-Peff



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux