summaryrefslogtreecommitdiff
path: root/Modules/_randommodule.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/_randommodule.c')
-rw-r--r--Modules/_randommodule.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/Modules/_randommodule.c b/Modules/_randommodule.c
index f0fdb0382c..7a8871868e 100644
--- a/Modules/_randommodule.c
+++ b/Modules/_randommodule.c
@@ -264,7 +264,6 @@ random_seed(RandomObject *self, PyObject *arg)
uint32_t *key = NULL;
size_t bits, keyused;
int res;
- PyObject *args[1];
if (arg == NULL || arg == Py_None) {
if (random_seed_urandom(self) < 0) {
@@ -286,9 +285,7 @@ random_seed(RandomObject *self, PyObject *arg)
} else if (PyLong_Check(arg)) {
/* Calling int.__abs__() prevents calling arg.__abs__(), which might
return an invalid value. See issue #31478. */
- args[0] = arg;
- n = PyObject_Vectorcall(_randomstate_global->Long___abs__, args, 0,
- NULL);
+ n = PyObject_CallOneArg(_randomstate_global->Long___abs__, arg);
}
else {
Py_hash_t hash = PyObject_Hash(arg);