mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-04-04 12:58:50 +00:00
Fixed memory leaks in SOGoSyncCacheObject and correctly kill the cache upon each EAS iteration
This commit is contained in:
@@ -55,7 +55,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
[o setUID: theUID];
|
||||
[o setSequence: theSequence];
|
||||
|
||||
return o;
|
||||
return [o autorelease];
|
||||
}
|
||||
|
||||
- (void) dealloc
|
||||
|
||||
@@ -43,10 +43,6 @@
|
||||
|
||||
@implementation SOGoMailBaseObject
|
||||
|
||||
#if 0
|
||||
static BOOL debugOn = YES;
|
||||
#endif
|
||||
|
||||
- (id) initWithImap4URL: (NSURL *) _url
|
||||
inContainer: (id) _container
|
||||
{
|
||||
|
||||
@@ -123,6 +123,9 @@
|
||||
return label;
|
||||
}
|
||||
|
||||
//
|
||||
// Set SOGoDebugLeaks = YES in your defaults to enable.
|
||||
//
|
||||
+ (void) memoryStatistics
|
||||
{
|
||||
Class *classList = GSDebugAllocationClassList ();
|
||||
|
||||
@@ -21,6 +21,8 @@
|
||||
|
||||
#import <Foundation/NSBundle.h>
|
||||
|
||||
#import <SOGo/SOGoCache.h>
|
||||
#import <SOGo/NSObject+Utilities.h>
|
||||
#import <SOGo/SOGoFolder.h>
|
||||
|
||||
#import <NGObjWeb/NSException+HTTP.h>
|
||||
@@ -54,13 +56,17 @@
|
||||
|
||||
ex = [dispatcher dispatchRequest: request inResponse: response context: context];
|
||||
|
||||
//[[self class] memoryStatistics];
|
||||
|
||||
if (ex)
|
||||
{
|
||||
return [NSException exceptionWithHTTPStatus: 500];
|
||||
}
|
||||
|
||||
RELEASE(dispatcher);
|
||||
|
||||
|
||||
[[SOGoCache sharedCache] killCache];
|
||||
|
||||
return response;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user