chiark
/
gitweb
/
~mdw
/
catacomb-python
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
catacomb/__init__.py: Import `sys' as a whole.
[catacomb-python]
/
mp.c
diff --git
a/mp.c
b/mp.c
index e9268e5a378981e232c9ce63b1e249b3e8196552..f2a00b996047ae91d7ba20a794dfcb5f325cf04c 100644
(file)
--- a/
mp.c
+++ b/
mp.c
@@
-211,6
+211,7
@@
mp *tomp(PyObject *o)
return (MP_COPY(PFILT_F(o)->m));
else if (ECPT_PYCHECK(o)) {
ec p = EC_INIT;
return (MP_COPY(PFILT_F(o)->m));
else if (ECPT_PYCHECK(o)) {
ec p = EC_INIT;
+ if (EC_ATINF(ECPT_P(o))) return (0);
getecptout(&p, o);
x = MP_COPY(p.x);
EC_DESTROY(&p);
getecptout(&p, o);
x = MP_COPY(p.x);
EC_DESTROY(&p);
@@
-1679,7
+1680,7
@@
static PyObject *mcmeth_solve(PyObject *me, PyObject *arg)
PyObject *q = 0, *x, *z = 0;
mp *xx;
mp **v = 0;
PyObject *q = 0, *x, *z = 0;
mp *xx;
mp **v = 0;
-
in
t i = 0, n = c->k;
+
Py_ssize_
t i = 0, n = c->k;
Py_INCREF(me);
if (PyTuple_Size(arg) == n)
Py_INCREF(me);
if (PyTuple_Size(arg) == n)
@@
-1718,7
+1719,7
@@
static void mpcrt_pydealloc(PyObject *me)
static PyObject *mpcrt_pynew(PyTypeObject *ty, PyObject *arg, PyObject *kw)
{
mpcrt_mod *v = 0;
static PyObject *mpcrt_pynew(PyTypeObject *ty, PyObject *arg, PyObject *kw)
{
mpcrt_mod *v = 0;
-
in
t n, i = 0, j;
+
Py_ssize_
t n, i = 0, j;
char *kwlist[] = { "mv", 0 };
PyObject *q = 0, *x;
mp *xx = MP_NEW, *y = MP_NEW, *g = MP_NEW;
char *kwlist[] = { "mv", 0 };
PyObject *q = 0, *x;
mp *xx = MP_NEW, *y = MP_NEW, *g = MP_NEW;