From e1eadab1b4c4faec2473f04a9a82987fe54d97f5 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Mon, 24 Mar 2008 02:33:42 +0000 Subject: [PATCH] fixed memory leak on disk io failures --- src/peer_connection.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/peer_connection.cpp b/src/peer_connection.cpp index 35fe73888..1a2ccd8f0 100755 --- a/src/peer_connection.cpp +++ b/src/peer_connection.cpp @@ -2508,6 +2508,7 @@ namespace libtorrent if (ret != r.length || m_torrent.expired()) { + if (j.buffer) m_ses.free_disk_buffer(j.buffer); boost::shared_ptr t = m_torrent.lock(); if (!t) {