New submission from Serhiy Storchaka:

Currently PyUnicode_FromFormat doesn't check an argument for %c and can raise 
SystemError only due maxchar check in PyUnicode_New. On 2.7 an error doesn't 
raised, but %c argument can be silently wrapped (on narrow build) or illegal 
Unicode string can be created (on wide build). The proposed patch adds explicit 
range check for %c argument.

----------
components: Interpreter Core, Unicode
files: format_c.diff
keywords: patch
messages: 190935
nosy: ezio.melotti, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Add range check  for %c in PyUnicode_FromFormat
type: behavior
versions: Python 2.7, Python 3.3, Python 3.4
Added file: http://bugs.python.org/file30535/format_c.diff

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue18184>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to