ACTUAL fix for this bug

This commit is contained in:
Michael Greene
2019-08-01 19:24:36 -07:00
parent 3d653f4d9f
commit e19e4181af
2 changed files with 4 additions and 2 deletions

View File

@@ -43,7 +43,7 @@ class Header(_Header):
def __init__(self):
super(Header, self).__init__()
self.typeid = -1
self._typeid = -1
self.critical = False
def parse(self, packet):
@@ -78,7 +78,7 @@ class SubPacket(Dispatchable):
self.header = Header()
# if self.__typeid__ not in [-1, None]:
if (self.header.typeid == 0x00 and
if (self.header.typeid == -1 and
(not hasattr(self.__typeid__, '__abstractmethod__')) and
(self.__typeid__ not in [-1, None])):
self.header.typeid = self.__typeid__

View File

@@ -635,6 +635,8 @@ class TestPGPKey_Actions(object):
key_data = gpg.Data(string=str(pubkey))
gpg.core.gpgme.gpgme_op_import(c.wrapped, key_data)
print(list(c.keylist()))
vargs = [gpg.Data(string=str(subject))]
if sig is not None:
vargs += [gpg.Data(string=str(sig))]