[openssl-dev] [libcrypto EVP] valgrind reports many memory leaks in wiki-example

U.Mutlu for-gmane at mutluit.com
Mon Nov 23 05:32:43 UTC 2015


Hi,
running the following example from the openssl wiki site under valgrind
gives many memory-leaks in the underlying library functions:
https://wiki.openssl.org/index.php/EVP_Symmetric_Encryption_and_Decryption

$ gcc -Wall -O2 test_encdec.c -lcrypto
$ valgrind --tool=memcheck --leak-check=full --show-leak-kinds=all 
--track-origins=yes -v ./a.out &>valgrind-output.txt

Attached is the valgrind-output. It says:
   34 not-freed blocks

Are these maybe false-positives? The leak summary in the output says this:
==9895== LEAK SUMMARY:
==9895==    definitely lost: 0 bytes in 0 blocks
==9895==    indirectly lost: 0 bytes in 0 blocks
==9895==      possibly lost: 0 bytes in 0 blocks
==9895==    still reachable: 2,632 bytes in 34 blocks
==9895==         suppressed: 0 bytes in 0 blocks

OS: Debian 8 amd64, using libs from the Debian repo:
libcrypto: 5.6.1-6+deb8u1
openssl: 1.0.1k-3+deb8u1

-- 
U.Mutlu
-------------- next part --------------
A non-text attachment was scrubbed...
Name: valgrind-output.txt.gz
Type: application/gzip
Size: 3231 bytes
Desc: not available
URL: <http://mta.openssl.org/pipermail/openssl-dev/attachments/20151123/d1b26820/attachment-0001.bin>


More information about the openssl-dev mailing list