Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

select.select crashes on resized lists #60434

Closed
serhiy-storchaka opened this issue Oct 14, 2012 · 4 comments
Closed

select.select crashes on resized lists #60434

serhiy-storchaka opened this issue Oct 14, 2012 · 4 comments
Labels
extension-modules C modules in the Modules dir type-crash A hard crash of the interpreter, possibly with a core dump

Comments

@serhiy-storchaka
Copy link
Member

BPO 16230
Nosy @jcea, @pitrou, @asvetlov, @serhiy-storchaka
Files
  • select_resized_list.patch
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2012-11-01.19:23:50.407>
    created_at = <Date 2012-10-14.10:37:16.530>
    labels = ['extension-modules', 'type-crash']
    title = 'select.select crashes on resized lists'
    updated_at = <Date 2012-11-01.19:23:50.376>
    user = 'https://github.com/serhiy-storchaka'

    bugs.python.org fields:

    activity = <Date 2012-11-01.19:23:50.376>
    actor = 'pitrou'
    assignee = 'none'
    closed = True
    closed_date = <Date 2012-11-01.19:23:50.407>
    closer = 'pitrou'
    components = ['Extension Modules']
    creation = <Date 2012-10-14.10:37:16.530>
    creator = 'serhiy.storchaka'
    dependencies = []
    files = ['27564']
    hgrepos = []
    issue_num = 16230
    keywords = ['patch', 'needs review']
    message_count = 4.0
    messages = ['172871', '172872', '174446', '174447']
    nosy_count = 5.0
    nosy_names = ['jcea', 'pitrou', 'asvetlov', 'python-dev', 'serhiy.storchaka']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'crash'
    url = 'https://bugs.python.org/issue16230'
    versions = ['Python 2.7', 'Python 3.2', 'Python 3.3', 'Python 3.4']

    @serhiy-storchaka
    Copy link
    Member Author

    Simple crash code:

    import select
    a = []
    class F:
        def fileno(self):
            del a[-1]
            return 1

    a[:] = [F()] * 10
    select.select([], a, [])

    @serhiy-storchaka serhiy-storchaka added extension-modules C modules in the Modules dir type-crash A hard crash of the interpreter, possibly with a core dump labels Oct 14, 2012
    @serhiy-storchaka
    Copy link
    Member Author

    Here is a patch.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Nov 1, 2012

    New changeset 87ccf2635ad7 by Antoine Pitrou in branch '3.2':
    Issue bpo-16230: Fix a crash in select.select() when one the lists changes size while iterated on.
    http://hg.python.org/cpython/rev/87ccf2635ad7

    New changeset 717660ec8f67 by Antoine Pitrou in branch '3.3':
    Issue bpo-16230: Fix a crash in select.select() when one the lists changes size while iterated on.
    http://hg.python.org/cpython/rev/717660ec8f67

    New changeset 823898ef37ce by Antoine Pitrou in branch 'default':
    Issue bpo-16230: Fix a crash in select.select() when one the lists changes size while iterated on.
    http://hg.python.org/cpython/rev/823898ef37ce

    New changeset 02a5322b0cee by Antoine Pitrou in branch '2.7':
    Issue bpo-16230: Fix a crash in select.select() when one the lists changes size while iterated on.
    http://hg.python.org/cpython/rev/02a5322b0cee

    @pitrou
    Copy link
    Member

    pitrou commented Nov 1, 2012

    Committed, thank you!

    @pitrou pitrou closed this as completed Nov 1, 2012
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    extension-modules C modules in the Modules dir type-crash A hard crash of the interpreter, possibly with a core dump
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants