ObjFW  Diff

Differences From Artifact [e300d0925e]:

To Artifact [700f57a4db]:


841
842
843
844
845
846
847
848
849


850


851
852
853
854
855
856


857
858

859


860
861
862
863
864
865
866
841
842
843
844
845
846
847


848
849
850
851
852
853
854
855
856


857
858
859

860
861
862
863
864
865
866
867
868
869
870







-
-
+
+

+
+




-
-
+
+

-
+

+
+








	[_stream release];
	[_entry release];

	[super dealloc];
}

- (void)lowlevelWriteBuffer: (const void *)buffer
		     length: (size_t)length
- (size_t)lowlevelWriteBuffer: (const void *)buffer
		       length: (size_t)length
{
	size_t bytesWritten;

	if ((sizeof(length) >= sizeof(int64_t) && length > INT64_MAX) ||
	    INT64_MAX - _bytesWritten < (int64_t)length)
		@throw [OFOutOfRangeException exception];

	[_stream writeBuffer: buffer
		      length: length];
	bytesWritten = [_stream writeBuffer: buffer
				     length: length];

	_bytesWritten += (int64_t)length;
	_bytesWritten += (int64_t)bytesWritten;
	_CRC32 = of_crc32(_CRC32, buffer, length);

	return bytesWritten;
}

- (void)close
{
	if (_stream == nil)
		return;