Skip to content

Commit 614b48c

Browse files
committed
revert some naming
1 parent b843fbf commit 614b48c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Modules/_hashopenssl.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2280,7 +2280,7 @@ _hashlib_HMAC_update_impl(HMACobject *self, PyObject *msg)
22802280
* On error, set an exception and return BAD_DIGEST_SIZE.
22812281
*/
22822282
static unsigned int
2283-
hashlib_openssl_HMAC_digest_size(HMACobject *self)
2283+
_hashlib_hmac_digest_size(HMACobject *self)
22842284
{
22852285
assert(EVP_MAX_MD_SIZE < INT_MAX);
22862286
#ifdef Py_HAS_OPENSSL3_SUPPORT
@@ -2314,9 +2314,9 @@ hashlib_openssl_HMAC_digest_size(HMACobject *self)
23142314
* On error, set an exception and return -1.
23152315
*/
23162316
static Py_ssize_t
2317-
hashlib_openssl_HMAC_digest_compute(HMACobject *self, unsigned char *buf)
2317+
_hmac_digest(HMACobject *self, unsigned char *buf)
23182318
{
2319-
unsigned int digest_size = hashlib_openssl_HMAC_digest_size(self);
2319+
unsigned int digest_size = _hashlib_hmac_digest_size(self);
23202320
assert(digest_size <= EVP_MAX_MD_SIZE);
23212321
if (digest_size == BAD_DIGEST_SIZE) {
23222322
assert(PyErr_Occurred());
@@ -2353,7 +2353,7 @@ _hashlib_HMAC_digest_impl(HMACobject *self)
23532353
/*[clinic end generated code: output=1b1424355af7a41e input=bff07f74da318fb4]*/
23542354
{
23552355
unsigned char buf[EVP_MAX_MD_SIZE];
2356-
Py_ssize_t n = hashlib_openssl_HMAC_digest_compute(self, buf);
2356+
Py_ssize_t n = _hmac_digest(self, buf);
23572357
return n < 0 ? NULL : PyBytes_FromStringAndSize((const char *)buf, n);
23582358
}
23592359

@@ -2373,15 +2373,15 @@ _hashlib_HMAC_hexdigest_impl(HMACobject *self)
23732373
/*[clinic end generated code: output=80d825be1eaae6a7 input=5e48db83ab1a4d19]*/
23742374
{
23752375
unsigned char buf[EVP_MAX_MD_SIZE];
2376-
Py_ssize_t n = hashlib_openssl_HMAC_digest_compute(self, buf);
2376+
Py_ssize_t n = _hmac_digest(self, buf);
23772377
return n < 0 ? NULL : _Py_strhex((const char *)buf, n);
23782378
}
23792379

23802380
static PyObject *
23812381
_hashlib_hmac_get_digest_size(PyObject *op, void *Py_UNUSED(closure))
23822382
{
23832383
HMACobject *self = HMACobject_CAST(op);
2384-
unsigned int size = hashlib_openssl_HMAC_digest_size(self);
2384+
unsigned int size = _hashlib_hmac_digest_size(self);
23852385
return size == BAD_DIGEST_SIZE ? NULL : PyLong_FromLong(size);
23862386
}
23872387

0 commit comments

Comments
 (0)