diff options
author | Neal Norwitz <nnorwitz@gmail.com> | 2002-03-31 15:27:00 (GMT) |
---|---|---|
committer | Neal Norwitz <nnorwitz@gmail.com> | 2002-03-31 15:27:00 (GMT) |
commit | ba3a16c6c3d3da0903873e9464dbc540eaeda1f7 (patch) | |
tree | 6094d419dcf56dfdb9bdb50da0a15d0c0160573a /Modules/md5module.c | |
parent | 50905b557b2a46d4db432b7a9e61fe32afa557e3 (diff) | |
download | cpython-ba3a16c6c3d3da0903873e9464dbc540eaeda1f7.zip cpython-ba3a16c6c3d3da0903873e9464dbc540eaeda1f7.tar.gz cpython-ba3a16c6c3d3da0903873e9464dbc540eaeda1f7.tar.bz2 |
Remove METH_OLDARGS:
Convert METH_OLDARGS -> METH_VARARGS: also PyArg_Parse -> PyArg_ParseTuple
Convert METH_OLDARGS -> METH_NOARGS: remove args parameter
Please review. All tests pass, but some modules don't have tests.
I spot checked various functions to try to make sure nothing broke.
Diffstat (limited to 'Modules/md5module.c')
-rw-r--r-- | Modules/md5module.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/md5module.c b/Modules/md5module.c index fb904f4..a6068ff 100644 --- a/Modules/md5module.c +++ b/Modules/md5module.c @@ -52,7 +52,7 @@ md5_update(md5object *self, PyObject *args) unsigned char *cp; int len; - if (!PyArg_Parse(args, "s#", &cp, &len)) + if (!PyArg_ParseTuple(args, "s#:update", &cp, &len)) return NULL; MD5Update(&self->md5, cp, len); @@ -142,7 +142,7 @@ Return a copy (``clone'') of the md5 object."; static PyMethodDef md5_methods[] = { - {"update", (PyCFunction)md5_update, METH_OLDARGS, update_doc}, + {"update", (PyCFunction)md5_update, METH_VARARGS, update_doc}, {"digest", (PyCFunction)md5_digest, METH_NOARGS, digest_doc}, {"hexdigest", (PyCFunction)md5_hexdigest, METH_NOARGS, hexdigest_doc}, {"copy", (PyCFunction)md5_copy, METH_NOARGS, copy_doc}, |