| От | Tom Lane |
|---|---|
| Тема | pgsql: Remove memory leaks in isolationtester. |
| Дата | |
| Msg-id | E1lxXuT-0005kc-1m@gemulon.postgresql.org обсуждение исходный текст |
| Список | pgsql-committers |
Remove memory leaks in isolationtester. specscanner.l leaked a kilobyte of memory per token of the spec file. Apparently somebody thought that the introductory code block would be executed once; but it's once per yylex() call. A couple of functions in isolationtester.c leaked small amounts of memory due to not bothering to free one-time allocations. Might as well improve these so that valgrind gives this program a clean bill of health. Also get rid of an ugly static variable. Coverity complained about one of the one-time leaks, which led me to try valgrind'ing isolationtester, which led to discovery of the larger leak. Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/642c0697c96b9c6ba5d194653a329f7820565f01 Modified Files -------------- src/test/isolation/isolationtester.c | 20 +++++++++++++------- src/test/isolation/specscanner.l | 8 ++++++-- 2 files changed, 19 insertions(+), 9 deletions(-)
В списке pgsql-committers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера