Author DeKrain
Recipients DeKrain
Date 2018-08-29.16:18:52
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1535559532.49.0.56676864532.issue34543@psf.upfronthosting.co.za>
In-reply-to
Content
>>> from _struct import Struct
>>> s = Struct.__new__(Struct)
>>> s.unpack_from(b'asdf')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
SystemError: /Objects/tupleobject.c:84: Bad argument to internal function

In Modules/_struct.c:

static PyObject *
s_unpack_internal(PyStructObject *soself, const char *startfrom) {
...
PyObject *result = PyTuple_New(soself->s_len);
// soself->s_len is -1, set in Struct.__new__
History
Date User Action Args
2018-08-29 16:18:52DeKrainsetrecipients: + DeKrain
2018-08-29 16:18:52DeKrainsetmessageid: <1535559532.49.0.56676864532.issue34543@psf.upfronthosting.co.za>
2018-08-29 16:18:52DeKrainlinkissue34543 messages
2018-08-29 16:18:52DeKraincreate