]> git.ipfire.org Git - thirdparty/unbound.git/commit
Fix python module len() implementations 269/head
authorTorbjörn Lönnemark <tobbez@ryara.net>
Wed, 22 Jul 2020 01:05:19 +0000 (03:05 +0200)
committerTorbjörn Lönnemark <tobbez@ryara.net>
Wed, 22 Jul 2020 01:13:00 +0000 (03:13 +0200)
commit9af8080f2b9514d27c5858cb24a06c1803bf0dc7
tree4cf94896ce07406380eaf718e25be36de4f7a41f
parent753487ff7f3a77ef59a52175fc64c55d177aaf84
Fix python module len() implementations

They were all missing the 'self.' prefix when accessing the 'obj'
instance variable, causing the following exception when attempting to
call len() on (for example) a ReplyInfo_RRSet:

  File "/usr/lib/python3.7/site-packages/unboundmodule.py", line 377, in __len__
    def __len__(self): return obj.rrset_count
NameError: name 'obj' is not defined
pythonmod/interface.i