Message75086
| Author |
amaury.forgeotdarc |
| Recipients |
amaury.forgeotdarc, erickt, ocean-city |
| Date |
2008年10月22日.16:18:23 |
| SpamBayes Score |
8.311722e-08 |
| Marked as misclassified |
No |
| Message-id |
<1224692304.39.0.348777135136.issue4170@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
The pickle protocol should also check that __reduce__ returns iterators
(iterables are not enough).
The code below crashes the interpreter (twice ;-)
class C:
def __reduce__(self):
return C, (), None, None, []
class D:
def __reduce__(self):
return D, (), None, [], None
import pickle
pickle.dumps(C())
pickle.dumps(D()) |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2008年10月22日 16:18:24 | amaury.forgeotdarc | set | recipients:
+ amaury.forgeotdarc, ocean-city, erickt |
| 2008年10月22日 16:18:24 | amaury.forgeotdarc | set | messageid: <1224692304.39.0.348777135136.issue4170@psf.upfronthosting.co.za> |
| 2008年10月22日 16:18:23 | amaury.forgeotdarc | link | issue4170 messages |
| 2008年10月22日 16:18:23 | amaury.forgeotdarc | create |
|