diff options
author | David Reid <dreid@dreid.org> | 2013-11-12 14:26:10 -0800 |
---|---|---|
committer | David Reid <dreid@dreid.org> | 2013-11-12 14:26:10 -0800 |
commit | 9d0d94d97cb8ed8d15b24018e20c08cf1f7b78b4 (patch) | |
tree | f3d3bd0b7d01e38baf4ebd9273d255ef497c7f3c | |
parent | 0bcbb41964014926c3c604efff68f2d11b592035 (diff) | |
download | cryptography-9d0d94d97cb8ed8d15b24018e20c08cf1f7b78b4.tar.gz cryptography-9d0d94d97cb8ed8d15b24018e20c08cf1f7b78b4.tar.bz2 cryptography-9d0d94d97cb8ed8d15b24018e20c08cf1f7b78b4.zip |
Don't use self.__class__
-rw-r--r-- | cryptography/hazmat/bindings/openssl/backend.py | 2 | ||||
-rw-r--r-- | cryptography/hazmat/primitives/hmac.py | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/cryptography/hazmat/bindings/openssl/backend.py b/cryptography/hazmat/bindings/openssl/backend.py index 60d51305..4d1be3b0 100644 --- a/cryptography/hazmat/bindings/openssl/backend.py +++ b/cryptography/hazmat/bindings/openssl/backend.py @@ -344,7 +344,7 @@ class _HMACContext(object): copied_ctx, self._ctx ) assert res != 0 - return self.__class__( + return _HMACContext( self._backend, self._key, self.algorithm, ctx=copied_ctx ) diff --git a/cryptography/hazmat/primitives/hmac.py b/cryptography/hazmat/primitives/hmac.py index 27bc0fee..57a908c4 100644 --- a/cryptography/hazmat/primitives/hmac.py +++ b/cryptography/hazmat/primitives/hmac.py @@ -43,7 +43,7 @@ class HMAC(object): self._ctx.update(msg) def copy(self): - return self.__class__( + return HMAC( self._key, self.algorithm, ctx=self._ctx.copy(), backend=self._backend ) |