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

Fix for memory leak in WindowsError_str #43449

Closed
zseil mannequin opened this issue Jun 2, 2006 · 2 comments
Closed

Fix for memory leak in WindowsError_str #43449

zseil mannequin opened this issue Jun 2, 2006 · 2 comments
Labels
interpreter-core (Objects, Python, Grammar, and Parser dirs)

Comments

@zseil
Copy link
Mannequin

zseil mannequin commented Jun 2, 2006

BPO 1499797
Files
  • winerror_str.diff: patch against revision 46603
  • 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 2006-06-04.06:20:09.000>
    created_at = <Date 2006-06-02.20:46:24.000>
    labels = ['interpreter-core']
    title = 'Fix for memory leak in WindowsError_str'
    updated_at = <Date 2006-06-04.06:20:09.000>
    user = 'https://bugs.python.org/zseil'

    bugs.python.org fields:

    activity = <Date 2006-06-04.06:20:09.000>
    actor = 'nnorwitz'
    assignee = 'nnorwitz'
    closed = True
    closed_date = None
    closer = None
    components = ['Interpreter Core']
    creation = <Date 2006-06-02.20:46:24.000>
    creator = 'zseil'
    dependencies = []
    files = ['7306']
    hgrepos = []
    issue_num = 1499797
    keywords = ['patch']
    message_count = 2.0
    messages = ['50409', '50410']
    nosy_count = 2.0
    nosy_names = ['nnorwitz', 'zseil']
    pr_nums = []
    priority = 'normal'
    resolution = 'accepted'
    stage = None
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue1499797'
    versions = ['Python 2.5']

    @zseil
    Copy link
    Mannequin Author

    zseil mannequin commented Jun 2, 2006

    The same memory leak that Neal Norwitz found in
    EnvironmentError_str is also present in
    WindowsError_str.

    How to reproduce:

    Python 2.5a2 (trunk:46603M, Jun  2 2006, 22:37:47)
      ...
    >>> e = WindowsError(1, 'message', 'filename')
    [27062 refs]
    >>> s = str(e)
    [27065 refs]
    >>> s = str(e)
    [27066 refs]
    >>> s = str(e)
    [27067 refs]
    >>> del e.filename
    [27066 refs]
    >>> s = str(e)
    [27066 refs]
    >>> s = str(e)
    [27066 refs]
    >>> s = str(e)
    [27066 refs]

    This simple patch fixes it.

    @zseil zseil mannequin closed this as completed Jun 2, 2006
    @zseil zseil mannequin assigned nnorwitz Jun 2, 2006
    @zseil zseil mannequin added the interpreter-core (Objects, Python, Grammar, and Parser dirs) label Jun 2, 2006
    @zseil zseil mannequin closed this as completed Jun 2, 2006
    @zseil zseil mannequin assigned nnorwitz Jun 2, 2006
    @zseil zseil mannequin added the interpreter-core (Objects, Python, Grammar, and Parser dirs) label Jun 2, 2006
    @nnorwitz
    Copy link
    Mannequin

    nnorwitz mannequin commented Jun 4, 2006

    Logged In: YES
    user_id=33168

    Thanks!

    Committed revision 46639.

    @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
    interpreter-core (Objects, Python, Grammar, and Parser dirs)
    Projects
    None yet
    Development

    No branches or pull requests

    0 participants