This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ostcar
Recipients ostcar
Date 2015-03-27.13:05:09
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1427461510.09.0.808726067558.issue23790@psf.upfronthosting.co.za>
In-reply-to
Content
When xdrlib.Packer().pack_string() is called with an unsupported value, it raises a TypeError. But it calles self.pack_uint(n) before it raises the exception so the buffer is changed.

There are two possible solutions to solve this behaviour. The argument s can be tested to be supported, or undo the call of self.pack_uint(n).

I added two alternative patches for this two solutions.

This is my first patch for cpython, I hope it is ok.
History
Date User Action Args
2015-03-27 13:05:10ostcarsetrecipients: + ostcar
2015-03-27 13:05:10ostcarsetmessageid: <1427461510.09.0.808726067558.issue23790@psf.upfronthosting.co.za>
2015-03-27 13:05:10ostcarlinkissue23790 messages
2015-03-27 13:05:09ostcarcreate