bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Memory leak when using use_default_colors + delscreen


From: magiblot 1
Subject: Memory leak when using use_default_colors + delscreen
Date: Tue, 6 Dec 2022 15:22:40 +0000

Hello,

Consider the attached source code. When compiled and executed with Valgrind 
(--leak-check=full), I get a "definitely lost" warning which is probably an 
actual bug.

Reproduced with ncurses v6_3_20221203.

> 24 bytes in 1 blocks are definitely lost in loss record 2 of 3
>    at 0x4841888: malloc (in 
> /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
>    by 0x49F7E6A: tsearch (tsearch.c:337)
>    by 0x489E0E2: _nc_init_pair (lib_color.c:652)
>    by 0x48BD434: assume_default_colors_sp (lib_dft_fgbg.c:86)
>    by 0x1091B9: main (in /tmp/test)

Thank you!

Attachment: test.c
Description: test.c


reply via email to

[Prev in Thread] Current Thread [Next in Thread]