chiark
/
gitweb
/
~mdw
/
catacomb-python
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
0c87e81
)
algorithms.c: Add binding for `poly1305_flushzero'.
author
Mark Wooding
<mdw@distorted.org.uk>
Sat, 15 Apr 2017 13:34:33 +0000
(14:34 +0100)
committer
Mark Wooding
<mdw@distorted.org.uk>
Mon, 17 Apr 2017 16:26:51 +0000
(17:26 +0100)
algorithms.c
patch
|
blob
|
blame
|
history
diff --git
a/algorithms.c
b/algorithms.c
index 2dc2dda0673f757af5361f7621962fd78f3b32ae..cb594ca31dd604f8297ea964b9457390f52ca89d 100644
(file)
--- a/
algorithms.c
+++ b/
algorithms.c
@@
-1335,6
+1335,13
@@
static PyObject *polymeth_flush(PyObject *me, PyObject *arg)
RETURN_ME;
}
RETURN_ME;
}
+static PyObject *polymeth_flushzero(PyObject *me, PyObject *arg)
+{
+ if (!PyArg_ParseTuple(arg, ":flushzero")) return (0);
+ poly1305_flushzero(P1305_CTX(me));
+ RETURN_ME;
+}
+
static PyObject *polymeth_concat(PyObject *me, PyObject *arg)
{
PyObject *pre, *suff;
static PyObject *polymeth_concat(PyObject *me, PyObject *arg)
{
PyObject *pre, *suff;
@@
-1385,6
+1392,7
@@
static PyMethodDef poly1305hash_pymethods[] = {
#undef METHBUF_
METH (hashstrz, "P.hashstrz(STRING)")
METH (flush, "P.flush()")
#undef METHBUF_
METH (hashstrz, "P.hashstrz(STRING)")
METH (flush, "P.flush()")
+ METH (flushzero, "P.flushzero()")
METH (concat, "P.concat(PREFIX, SUFFIX)")
METH (done, "P.done() -> TAG")
#undef METHNAME
METH (concat, "P.concat(PREFIX, SUFFIX)")
METH (done, "P.done() -> TAG")
#undef METHNAME