From a194329365c142a2d2fd62b0a46d8b22eadb676a Mon Sep 17 00:00:00 2001 From: David Reid Date: Thu, 31 Oct 2013 15:40:48 -0700 Subject: Inline _copy_ctx --- cryptography/hazmat/primitives/hashes.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/cryptography/hazmat/primitives/hashes.py b/cryptography/hazmat/primitives/hashes.py index a50017bc..bdad5e16 100644 --- a/cryptography/hazmat/primitives/hashes.py +++ b/cryptography/hazmat/primitives/hashes.py @@ -43,15 +43,12 @@ class Hash(object): def copy(self): return self.__class__(self.algorithm, backend=self._backend, - ctx=self._copy_ctx()) + ctx=self._backend.hashes.copy_ctx(self._ctx)) def finalize(self): return self._backend.hashes.finalize_ctx(self._ctx, self.algorithm.digest_size) - def _copy_ctx(self): - return self._backend.hashes.copy_ctx(self._ctx) - @interfaces.register(interfaces.HashAlgorithm) class SHA1(object): -- cgit v1.2.3