ObjFW  Diff

Differences From Artifact [c8f541f60e]:

To Artifact [a552090953]:


143
144
145
146
147
148
149
150

151
152
153
154
155

156
157
158
159
160
161
162
143
144
145
146
147
148
149

150
151
152
153
154

155
156
157
158
159
160
161
162







-
+




-
+








@implementation OFZIPArchiveEntry
+ (instancetype)entryWithFileName: (OFString *)fileName
{
	return [[[self alloc] initWithFileName: fileName] autorelease];
}

- init
- (instancetype)init
{
	OF_INVALID_INIT_METHOD
}

- initWithFileName: (OFString *)fileName
- (instancetype)initWithFileName: (OFString *)fileName
{
	self = [super init];

	@try {
		void *pool = objc_autoreleasePoolPush();

		if ([fileName UTF8StringLength] > UINT16_MAX)
267
268
269
270
271
272
273
274

275
276
277
278
279

280
281
282
283
284
285
286
267
268
269
270
271
272
273

274
275
276
277
278

279
280
281
282
283
284
285
286







-
+




-
+







	[_fileName release];
	[_extraField release];
	[_fileComment release];

	[super dealloc];
}

- copy
- (id)copy
{
	return [self retain];
}

- mutableCopy
- (id)mutableCopy
{
	OFZIPArchiveEntry *copy =
	    [[OFMutableZIPArchiveEntry alloc] initWithFileName: _fileName];

	@try {
		copy->_versionMadeBy = _versionMadeBy;
		copy->_minVersionNeeded = _minVersionNeeded;