diff options
Diffstat (limited to 'src/core/imap/MCIMAPSession.cpp')
-rwxr-xr-x | src/core/imap/MCIMAPSession.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/imap/MCIMAPSession.cpp b/src/core/imap/MCIMAPSession.cpp index 466ff936..9fb80711 100755 --- a/src/core/imap/MCIMAPSession.cpp +++ b/src/core/imap/MCIMAPSession.cpp @@ -518,10 +518,12 @@ static void logger(mailimap * imap, int log_type, const char * buffer, size_t si return; bool isBuffer = isBufferFromLogType(log_type); - + if (isBuffer) { + AutoreleasePool * pool = new AutoreleasePool(); Data * data = Data::dataWithBytes(buffer, (unsigned int) size); session->connectionLogger()->log(session, type, data); + pool->release(); } else { session->connectionLogger()->log(session, type, NULL); |