chiark
/
gitweb
/
~mdw
/
catacomb-python
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
pwsafe, catacomb/pwsafe.py: Documentation and cleanup.
[catacomb-python]
/
group.c
diff --git
a/group.c
b/group.c
index cd3472f07d3d30f302589afb8fb319c360ae299b..1f733a092d87f49f3f2d7fb483d3d9ed85e3acdc 100644
(file)
--- a/
group.c
+++ b/
group.c
@@
-1,6
+1,4
@@
/* -*-c-*-
/* -*-c-*-
- *
- * $Id$
*
* Abstract group inteface
*
*
* Abstract group inteface
*
@@
-227,7
+225,7
@@
static PyObject *namedgroups(const pentry *pp, int *ne)
}
c = PyInt_FromLong(i);
found:
}
c = PyInt_FromLong(i);
found:
- PyDict_SetItemString(d, (/*unconst*/ char *)p
p[i].name
, c);
+ PyDict_SetItemString(d, (/*unconst*/ char *)p, c);
Py_DECREF(c);
}
*ne = i;
Py_DECREF(c);
}
*ne = i;
@@
-784,13
+782,13
@@
static PyObject *gmeth_mexp(PyObject *me, PyObject *arg)
gmexp_id, gmexp_fill, gmexp_exp, gmexp_drop));
}
gmexp_id, gmexp_fill, gmexp_exp, gmexp_drop));
}
-static PyObject *gmeth_check(PyObject *me, PyObject *arg, PyObject *kw)
+static PyObject *gmeth_check
group
(PyObject *me, PyObject *arg, PyObject *kw)
{
char *kwlist[] = { "rng", 0 };
grand *r = &rand_global;
const char *p;
{
char *kwlist[] = { "rng", 0 };
grand *r = &rand_global;
const char *p;
- if (!PyArg_ParseTupleAndKeywords(arg, kw, "|O&:check", kwlist,
+ if (!PyArg_ParseTupleAndKeywords(arg, kw, "|O&:check
group
", kwlist,
convgrand, &r))
goto end;
if ((p = G_CHECK(GROUP_G(me), r)) != 0)
convgrand, &r))
goto end;
if ((p = G_CHECK(GROUP_G(me), r)) != 0)
@@
-1051,7
+1049,7
@@
static PyMethodDef group_pymethods[] = {
#define METHNAME(name) gmeth_##name
METH (mexp, "\
G.mexp([(X0, N0), (X1, N1), ...]) -> X0^N0 X1^N1 ...")
#define METHNAME(name) gmeth_##name
METH (mexp, "\
G.mexp([(X0, N0), (X1, N1), ...]) -> X0^N0 X1^N1 ...")
- KWMETH(check
, "G.check
(rand = random): check group is good")
+ KWMETH(check
group, "G.checkgroup
(rand = random): check group is good")
#undef METHNAME
{ 0 }
};
#undef METHNAME
{ 0 }
};