[issue39307] Memory leak in parsetok

2020-01-13 Thread miss-islington


miss-islington  added the comment:


New changeset 9671b6b3b3e480fbc4b14aab7008b90b38767f55 by Miss Islington (bot) 
in branch '3.8':
bpo-39307: Fix memory leak on error path in parsetok (GH-17953)
https://github.com/python/cpython/commit/9671b6b3b3e480fbc4b14aab7008b90b38767f55


--
nosy: +miss-islington

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-13 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17384
pull_request: https://github.com/python/cpython/pull/17978

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17385
pull_request: https://github.com/python/cpython/pull/17979

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-13 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 7ba6f18de2582755ae31888ba6a4237d96dddc48 by Pablo Galindo (Alex 
Henrie) in branch 'master':
bpo-39307: Fix memory leak on error path in parsetok (GH-17953)
https://github.com/python/cpython/commit/7ba6f18de2582755ae31888ba6a4237d96dddc48


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-12 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +pablogsal

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-11 Thread Alex Henrie


Change by Alex Henrie :


--
keywords: +patch
pull_requests: +17363
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/17953

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39307] Memory leak in parsetok

2020-01-11 Thread Alex Henrie


New submission from Alex Henrie :

The parsetok function currently contains the following code:

if (!growable_comment_array_init(&type_ignores, 10)) {
err_ret->error = E_NOMEM;
PyTokenizer_Free(tok);
return NULL;
}

if ((ps = PyParser_New(g, start)) == NULL) {
err_ret->error = E_NOMEM;
PyTokenizer_Free(tok);
return NULL;
}

If PyParser_New fails, there is a memory leak because 
growable_comment_array_deallocate is not called on type_ignores.

--
components: Interpreter Core
messages: 359821
nosy: alex.henrie
priority: normal
severity: normal
status: open
title: Memory leak in parsetok
type: resource usage
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com