Fixed invalid use of freed memory.
This commit is contained in:
parent
b02e6ab664
commit
f0e12cbadc
@ -216,8 +216,9 @@ const vmime::string posixHandler::getHostName() const
|
||||
{
|
||||
if (isFQDN(p->ai_canonname))
|
||||
{
|
||||
const string ret(p->ai_canonname);
|
||||
freeaddrinfo(info);
|
||||
return p->ai_canonname;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -241,8 +241,9 @@ const vmime::string windowsHandler::getHostName() const
|
||||
{
|
||||
if (isFQDN(p->ai_canonname))
|
||||
{
|
||||
const string ret(p->ai_canonname);
|
||||
freeaddrinfo(info);
|
||||
return p->ai_canonname;
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user