From: Tim Peters Date: Sun, 2 Feb 2003 16:14:23 +0000 (+0000) Subject: dump(): Fixed a stupid bug in new code. It wasn't possible for the bug X-Git-Tag: v2.3c1~2117 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9b1e03ff4b6ffeeab04e8d2d59d17d12826a5dab;p=python dump(): Fixed a stupid bug in new code. It wasn't possible for the bug to have an effect before protocol 3 is invented, so no test can be written for this (yet). --- diff --git a/Modules/cPickle.c b/Modules/cPickle.c index 43a8d33102..17ccb45893 100644 --- a/Modules/cPickle.c +++ b/Modules/cPickle.c @@ -2217,7 +2217,7 @@ dump(Picklerobject *self, PyObject *args) char bytes[2]; bytes[0] = PROTO; - bytes[1] = CURRENT_PROTOCOL_NUMBER; + bytes[1] = self->proto; if (self->write_func(self, bytes, 2) < 0) return -1; }