@@ -170,39 +170,18 @@ *size = 0; return OFNotFound; } @implementation OFZIPArchiveEntry -+ (instancetype)entryWithFileName: (OFString *)fileName -{ - return [[[self alloc] initWithFileName: fileName] autorelease]; -} - - (instancetype)init { OF_INVALID_INIT_METHOD } -- (instancetype)initWithFileName: (OFString *)fileName -{ - self = [super init]; - - @try { - void *pool = objc_autoreleasePoolPush(); - - if (fileName.UTF8StringLength > UINT16_MAX) - @throw [OFOutOfRangeException exception]; - - _fileName = [fileName copy]; - - objc_autoreleasePoolPop(pool); - } @catch (id e) { - [self release]; - @throw e; - } - - return self; +- (instancetype)of_init +{ + return [super init]; } - (instancetype)of_initWithStream: (OFStream *)stream { self = [super init];