ObjFW  Diff

Differences From Artifact [c1512afd3b]:

To Artifact [b446679d60]:


105
106
107
108
109
110
111
112
113
114



115
116
117
118
119
120
121
105
106
107
108
109
110
111



112
113
114
115
116
117
118
119
120
121







-
-
-
+
+
+







				uint32_t u32[1024 / sizeof(uint32_t)];
			} buffer;
			bool empty = true;

			if (![_stream isKindOfClass: [OFSeekableStream class]])
				@throw [OFInvalidArgumentException exception];

			[(OFSeekableStream *)stream seekToOffset: -1024
							  whence: SEEK_END];
			[stream readIntoBuffer: buffer.c
			[(OFSeekableStream *)_stream seekToOffset: -1024
							   whence: SEEK_END];
			[_stream readIntoBuffer: buffer.c
				    exactLength: 1024];

			for (size_t i = 0; i < 1024 / sizeof(uint32_t); i++)
				if (buffer.u32[i] != 0)
					empty = false;

			if (!empty)