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

Python/coreconfig.c: Fix _Py_wstrlist_copy() #78673

Closed
izbyshev mannequin opened this issue Aug 24, 2018 · 4 comments
Closed

Python/coreconfig.c: Fix _Py_wstrlist_copy() #78673

izbyshev mannequin opened this issue Aug 24, 2018 · 4 comments
Labels
3.7 (EOL) end of life 3.8 only security fixes interpreter-core (Objects, Python, Grammar, and Parser dirs) type-bug An unexpected behavior, bug, or error

Comments

@izbyshev
Copy link
Mannequin

izbyshev mannequin commented Aug 24, 2018

BPO 34492
Nosy @vstinner, @berkerpeksag, @serhiy-storchaka, @izbyshev
PRs
  • bpo-34492: Python/coreconfig.c: Fix _Py_wstrlist_copy() #8910
  • [3.7] bpo-34492: Modules/main.c: Fix copy_wstrlist() (GH-8910) #8922
  • 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 2018-08-25.16:47:27.087>
    created_at = <Date 2018-08-24.22:37:17.803>
    labels = ['interpreter-core', '3.8', 'type-bug', '3.7']
    title = 'Python/coreconfig.c: Fix _Py_wstrlist_copy()'
    updated_at = <Date 2018-08-25.16:47:27.086>
    user = 'https://github.com/izbyshev'

    bugs.python.org fields:

    activity = <Date 2018-08-25.16:47:27.086>
    actor = 'vstinner'
    assignee = 'none'
    closed = True
    closed_date = <Date 2018-08-25.16:47:27.087>
    closer = 'vstinner'
    components = ['Interpreter Core']
    creation = <Date 2018-08-24.22:37:17.803>
    creator = 'izbyshev'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 34492
    keywords = ['patch']
    message_count = 4.0
    messages = ['324021', '324023', '324078', '324079']
    nosy_count = 4.0
    nosy_names = ['vstinner', 'berker.peksag', 'serhiy.storchaka', 'izbyshev']
    pr_nums = ['8910', '8922']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue34492'
    versions = ['Python 3.7', 'Python 3.8']

    @izbyshev
    Copy link
    Mannequin Author

    izbyshev mannequin commented Aug 24, 2018

    The return value of PyMem_RawMalloc() is not checked for NULL at

    wchar_t **list_copy = PyMem_RawMalloc(size);
    .

    Reported by Svace static analyzer.

    @izbyshev izbyshev mannequin added 3.8 only security fixes interpreter-core (Objects, Python, Grammar, and Parser dirs) type-bug An unexpected behavior, bug, or error labels Aug 24, 2018
    @vstinner
    Copy link
    Member

    New changeset eb746db by Victor Stinner (Alexey Izbyshev) in branch 'master':
    bpo-34492: Python/coreconfig.c: Fix _Py_wstrlist_copy() (GH-8910)
    eb746db

    @izbyshev izbyshev mannequin added the 3.7 (EOL) end of life label Aug 25, 2018
    @izbyshev izbyshev mannequin changed the title Python/coreconfig.c: Missing NULL check in _Py_wstrlist_copy() Python/coreconfig.c: Fix _Py_wstrlist_copy() Aug 25, 2018
    @vstinner
    Copy link
    Member

    New changeset 388bd4b by Victor Stinner (Alexey Izbyshev) in branch '3.7':
    [3.7] bpo-34492: Modules/main.c: Fix copy_wstrlist() (GH-8910) (GH-8922)
    388bd4b

    @vstinner
    Copy link
    Member

    Thanks Alexey Izbyshev for the bug report and the fix for 3.7 and master branches!

    @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 interpreter-core (Objects, Python, Grammar, and Parser dirs) type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant