summaryrefslogtreecommitdiffstats
path: root/Modules/sha1module.c
diff options
context:
space:
mode:
authorChristian Heimes <christian@python.org>2021-05-02 07:47:45 (GMT)
committerGitHub <noreply@github.com>2021-05-02 07:47:45 (GMT)
commit91554e4c5ca3c762998296522f854a7166ba84f0 (patch)
treeaa6e08eedef59c4a4d5c750ed60e5d463f05a4ad /Modules/sha1module.c
parentfd0bc7e7f4f2c7de98a1ebc7ad1ef65b8f8f7ad6 (diff)
downloadcpython-91554e4c5ca3c762998296522f854a7166ba84f0.zip
cpython-91554e4c5ca3c762998296522f854a7166ba84f0.tar.gz
cpython-91554e4c5ca3c762998296522f854a7166ba84f0.tar.bz2
bpo-43908: Mark ssl, hash, and hmac types as immutable (GH-25792)
Signed-off-by: Christian Heimes <christian@python.org>
Diffstat (limited to 'Modules/sha1module.c')
-rw-r--r--Modules/sha1module.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/sha1module.c b/Modules/sha1module.c
index 9ac46c5..1d4bde2 100644
--- a/Modules/sha1module.c
+++ b/Modules/sha1module.c
@@ -462,7 +462,7 @@ static PyType_Slot sha1_type_slots[] = {
static PyType_Spec sha1_type_spec = {
.name = "_sha1.sha1",
.basicsize = sizeof(SHA1object),
- .flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_DISALLOW_INSTANTIATION,
+ .flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_DISALLOW_INSTANTIATION | Py_TPFLAGS_IMMUTABLETYPE,
.slots = sha1_type_slots
};