Patches item #1680015, was opened at 2007-03-13 17:44 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1680015&group_id=5470
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Core (C code) Group: Python 2.5 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Žiga Seilnacht (zseil) Assigned to: Nobody/Anonymous (nobody) Summary: __slots__ tuple modified inplace if it contains unicode name Initial Comment: Function _unicode_to_string() in typeobject.c tries to copy the original tuple by asking for a complete slice of the original tuple. This case is special cased in tupleslice() to only incref the original tuple. As a consequence, the user's tuple could be modified (see the test). There are also some reference leaks if an unicode name can't be encoded with the default codec. The patch fixes this and adds tests for both cases. I also moved a comment about possible leaks to the appropriate place. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1680015&group_id=5470 _______________________________________________ Patches mailing list Patches@python.org http://mail.python.org/mailman/listinfo/patches