BIND 10 #394: memory leaks in branches/trac327 (after io_service refactors)
BIND 10 Development
do-not-reply at isc.org
Wed Oct 27 10:03:14 UTC 2010
#394: memory leaks in branches/trac327 (after io_service refactors)
-------------------------------+--------------------------------------------
Reporter: jelte | Owner:
Type: defect | Status: new
Priority: major | Milestone:
Component: Unclassified | Resolution:
Keywords: | Sensitive: 0
Estimatedhours: 0.0 | Hours: 0
Billable: 1 | Totalhours: 0
Internal: 0 |
-------------------------------+--------------------------------------------
Comment(by jinmei):
Replying to [comment:1 jelte]:
> I've fixed a few other memory-related problems in r3369, but these were
not the big ones.
>
> I've identified at least three places where new is used without a
matching delete, but I'm not sure where to delete these (and/or if we can
reach them at that point right now):
>
> - When RecursiveQuery::sendQuery() creates a UDPQuery object
(asiolink.cc:240) , the constructor clones the DNSServer (udpdns.cc:180).
This clone is never deleted.
> - udpdns.cc also does two news at line 109 and 110 which aren't freed
>
From a quick look, memory for "peer" and "iosock" seems to leak due to the
following:
{{{
peer = new TCPEndpoint(socket_->remote_endpoint());
iosock = new TCPSocket(*socket_);
io_message_.reset(new IOMessage(data_.get(), length, *iosock,
*peer));
}}}
(in src/lib/asiolink/tcpdns.cc)
(for that matter this code is not exception safe, either)
--
Ticket URL: <http://bind10.isc.org/ticket/394#comment:2>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development
More information about the bind10-tickets
mailing list