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

[EASY C] test_posix.test_posix_spawn_file_actions() leaks memory #77538

Closed
vstinner opened this issue Apr 25, 2018 · 3 comments
Closed

[EASY C] test_posix.test_posix_spawn_file_actions() leaks memory #77538

vstinner opened this issue Apr 25, 2018 · 3 comments
Labels
3.7 (EOL) end of life 3.8 only security fixes tests Tests in the Lib/test dir

Comments

@vstinner
Copy link
Member

BPO 33357
Nosy @vstinner, @pablogsal
Superseder
  • bpo-20104: expose posix_spawn(p)
  • 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-05-29.21:32:22.457>
    created_at = <Date 2018-04-25.14:39:14.611>
    labels = ['3.8', '3.7', 'tests']
    title = '[EASY C] test_posix.test_posix_spawn_file_actions() leaks memory'
    updated_at = <Date 2018-05-29.21:32:22.456>
    user = 'https://github.com/vstinner'

    bugs.python.org fields:

    activity = <Date 2018-05-29.21:32:22.456>
    actor = 'vstinner'
    assignee = 'none'
    closed = True
    closed_date = <Date 2018-05-29.21:32:22.457>
    closer = 'vstinner'
    components = ['Tests']
    creation = <Date 2018-04-25.14:39:14.611>
    creator = 'vstinner'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 33357
    keywords = []
    message_count = 3.0
    messages = ['315740', '315743', '315744']
    nosy_count = 2.0
    nosy_names = ['vstinner', 'pablogsal']
    pr_nums = []
    priority = 'normal'
    resolution = 'duplicate'
    stage = 'resolved'
    status = 'closed'
    superseder = '20104'
    type = None
    url = 'https://bugs.python.org/issue33357'
    versions = ['Python 3.7', 'Python 3.8']

    @vstinner
    Copy link
    Member Author

    vstinner@apu$ ./python -m test test_posix -R 3:3 -m test.test_posix.PosixTester.test_posix_spawn_file_actions
    Run tests sequentially
    0:00:00 load avg: 0.58 [1/1] test_posix
    beginning 6 repetitions
    123456
    ......
    test_posix leaked [7, 7, 7] references, sum=21
    test_posix leaked [1, 2, 1] memory blocks, sum=4
    test_posix failed

    1 test failed:
    test_posix

    Total duration: 315 ms
    Tests result: FAILURE

    I bet that the leak was introduced by:

    commit 6c6ddf9
    Author: Pablo Galindo <Pablogsal@gmail.com>
    Date: Mon Jan 29 01:56:10 2018 +0000

    bpo-20104: Expose `posix_spawn` in the os module (GH-5109)
    
    Add os.posix_spawn to wrap the low level POSIX API of the same name.
    
    Contributed by Pablo Galindo.
    

    --

    IMHO this issue is easy to fix, so I suggest to leave it to new contributors, or the author of the change.

    @vstinner vstinner added 3.7 (EOL) end of life 3.8 only security fixes tests Tests in the Lib/test dir labels Apr 25, 2018
    @pablogsal
    Copy link
    Member

    I think PR6332 is already addressing this #6332 , right?

    @vstinner
    Copy link
    Member Author

    I confirm that PR 6332 fixes the leak.

    @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 tests Tests in the Lib/test dir
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants