Topic "Memory Leak"

Author Message
Firewave
[View user's profile]

Joined: 2009-05-21
Posts: 8
According to cppcheck, there is a memory leak in the method TKeyGenerator::GetPublicKey() in core/K-e-y-G-e-n.cpp:

[c:\Documents and Settings\Administrator\My Documents\Downloads\winscp421source\core\K-e-y-G-e-n.cpp:342]: (error) Mismatching allocation and deallocation: buffer

Looking at the code confirms it as the memory is allocated as a memory, but not freed as such. Just used "delete []" instead.

PS: I had to change the name of the sourcefile as your spam filter forbids me to post it.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
Thanks. Will check it. Though this source file is not used at all currently.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License