DamionWaltermeyer / dpkt

Automatically exported from code.google.com/p/dpkt
Other
0 stars 0 forks source link

error in 'type' property in vrrp.py #100

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

In vrrp.py

   def _get_v(self):
        return self.vtype >> 4
    def _set_v(self, v):
        self.vtype = (self.vtype & ~0xf) | (v << 4)
    v = property(_get_v, _set_v)

    def _get_type(self):
        return self.vtype & 0xf
    def _set_type(self, v):
        self.vtype = (self.vtype & ~0xf0) | (v & 0xf)
    type = property(_get_v, _set_v)

the last line is setting up the 'type' property to use the 'v' helper 
functions, it should use the 'type' helper functions. line should read 

    type = property(_get_type, _set_type)

Original issue reported on code.google.com by kgla...@gmail.com on 8 Jan 2013 at 9:44

GoogleCodeExporter commented 9 years ago
Fixed in r88

Original comment by andrewf...@gmail.com on 5 Mar 2013 at 7:43