fixed 2 uninitialized memory read

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8441 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2015-06-14 15:15:41 +00:00
parent 3f9180b999
commit 3eb673dc53
2 changed files with 3 additions and 3 deletions

View File

@ -218,7 +218,8 @@ int p3BitDht::addBadPeer(const struct sockaddr_storage &addr, uint32_t /*reason*
int p3BitDht::addKnownPeer(const RsPeerId &pid, const struct sockaddr_storage &addr, uint32_t flags)
{
struct sockaddr_in addrv4;
struct sockaddr_in addrv4;
sockaddr_clear(&addrv4);
if (addr.ss_family != AF_INET)
{
@ -227,7 +228,6 @@ int p3BitDht::addKnownPeer(const RsPeerId &pid, const struct sockaddr_storage &a
std::cerr << "p3BitDht::addKnownPeer() Warning! Non IPv4 Address - Cannot handle IPV6 Yet. addr.ss_family=" << addr.ss_family;
std::cerr << std::endl;
}
sockaddr_clear(&addrv4);
if (flags & NETASSIST_KNOWN_PEER_ONLINE)
{

View File

@ -795,7 +795,7 @@ bool RsCollectionDialog::addAllChild(QFileInfo &fileInfoParent
*/
void RsCollectionDialog::remove()
{
bool removeOnlyFile;
bool removeOnlyFile=false;
QString listDir;
// First, check if selection contains directories
for (int curs = 0; curs < ui._fileEntriesTW->selectedItems().count(); ++curs)