On Thu, 30 May 2013 11:04:48 +0900 Isaku Yamahata <[email protected]> wrote:
> > On Tue, May 28, 2013 at 04:54:17PM +0000, Shaun Crampton wrote: >> Hi, > > Hi. Now I understand the point. > Let's drop adding padding part and implement truncate padding in clean > way instead of ad-hoc enhance like checking total_length. > How about this > > PacketBase > def __init__ > ... > self.payload_size = 0 > > parser of subclass of PacketBase sets self.payload_size > 0 if necessary. > Packet._parser truncates padding if proto.payload_size > 0. > And modify related subclasses. ipv4, ipv6, udp... Please send a patch based on your suggestion. Then we can see the difference between two approaches clearly. ------------------------------------------------------------------------------ Get 100% visibility into Java/.NET code with AppDynamics Lite It's a free troubleshooting tool designed for production Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap2 _______________________________________________ Ryu-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ryu-devel
