On Fri, Sep 4, 2009 at 3:54 PM, David Warde-Farley <d...@cs.toronto.edu>wrote:
> On 4-Sep-09, at 4:23 PM, Charles R Harris wrote: > > > The odd values might be from the format code in the error message: > > > > PyErr_Format(PyExc_ValueError, > > "%ld requested and %ld written", > > (long) size, (long) n); > > > > The code that is immediately responsible for the write is in lines > > 79-92 of > > convert.c. You could do a bit of poking around in there to find out > > what is > > happening. > > > Yes, I saw that. My C is rusty, but wouldn't the cast take care of it? > n is of type size_t, which is pretty big, and a cast to long shouldn't > be an issue. And if (hopefully) PyErr_Format is correct... > > Well, I don't have access, but this smells like an overflow problem. It would be nice to know what the actual sizes of the numbers are. Chuck
_______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion