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

Missing Py_DECREF in task_step_impl() in _asynciomodule.c #84739

Closed
cjerdonek opened this issue May 8, 2020 · 5 comments
Closed

Missing Py_DECREF in task_step_impl() in _asynciomodule.c #84739

cjerdonek opened this issue May 8, 2020 · 5 comments
Labels
3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes performance Performance or resource usage topic-asyncio

Comments

@cjerdonek
Copy link
Member

BPO 40559
Nosy @asvetlov, @cjerdonek, @1st1, @miss-islington
PRs
  • bpo-40559: Add Py_DECREF to _asynciomodule.c:task_step_impl() #19990
  • [3.8] bpo-40559: Add Py_DECREF to _asynciomodule.c:task_step_impl() (GH-19990) #19995
  • [3.7] bpo-40559: Add Py_DECREF to _asynciomodule.c:task_step_impl() (GH-19990) #19996
  • 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 2020-05-08.11:47:23.803>
    created_at = <Date 2020-05-08.07:40:03.008>
    labels = ['3.8', 'expert-asyncio', '3.7', '3.9', 'performance']
    title = 'Missing Py_DECREF in task_step_impl() in _asynciomodule.c'
    updated_at = <Date 2020-05-08.11:47:23.803>
    user = 'https://github.com/cjerdonek'

    bugs.python.org fields:

    activity = <Date 2020-05-08.11:47:23.803>
    actor = 'chris.jerdonek'
    assignee = 'none'
    closed = True
    closed_date = <Date 2020-05-08.11:47:23.803>
    closer = 'chris.jerdonek'
    components = ['asyncio']
    creation = <Date 2020-05-08.07:40:03.008>
    creator = 'chris.jerdonek'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 40559
    keywords = ['patch']
    message_count = 5.0
    messages = ['368425', '368426', '368432', '368433', '368434']
    nosy_count = 4.0
    nosy_names = ['asvetlov', 'chris.jerdonek', 'yselivanov', 'miss-islington']
    pr_nums = ['19990', '19995', '19996']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'resource usage'
    url = 'https://bugs.python.org/issue40559'
    versions = ['Python 3.7', 'Python 3.8', 'Python 3.9']

    @cjerdonek
    Copy link
    Member Author

    There is a missing Py_DECREF in task_step_impl() in _asynciomodule.c:

    return NULL;

    It should have the form:

        if (clear_exc) {
            Py_DECREF(exc);
        }

    This was introduced here in 3.7:
    bca4939

    I'm not sure of the likelihood of this ever getting triggered (it appears to be unlikely), but it should still be addressed.

    I will file a patch shortly.

    @cjerdonek cjerdonek added 3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes topic-asyncio performance Performance or resource usage labels May 8, 2020
    @cjerdonek
    Copy link
    Member Author

    Here is the original issue: https://bugs.python.org/issue31185

    @cjerdonek
    Copy link
    Member Author

    New changeset d2c349b by Chris Jerdonek in branch 'master':
    bpo-40559: Add Py_DECREF to _asynciomodule.c:task_step_impl() (GH-19990)
    d2c349b

    @cjerdonek
    Copy link
    Member Author

    New changeset 0e4a5e9 by Miss Islington (bot) in branch '3.8':
    [3.8] bpo-40559: Add Py_DECREF to _asynciomodule.c:task_step_impl() (GH-19990)
    0e4a5e9

    @cjerdonek
    Copy link
    Member Author

    New changeset 2501428 by Miss Islington (bot) in branch '3.7':
    [3.7] bpo-40559: Add Py_DECREF to _asynciomodule.c:task_step_impl() (GH-19990)
    2501428

    @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
    3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes performance Performance or resource usage topic-asyncio
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant