ObjFW  Diff

Differences From Artifact [3bbaec8fd0]:

To Artifact [28d8f0b089]:


154
155
156
157
158
159
160
161
162
163
164
165
166
167
168

- removeNObjects: (size_t)nobjects
	 atIndex: (size_t)index
{
	OFObject **objs = [array cArray];
	size_t i, count = [array count];

	if (nobjects > count)
		@throw [OFOutOfRangeException newWithClass: isa];

	for (i = index; i < count && i < index + nobjects; i++)
		[objs[i] release];

	[array removeNItems: nobjects
		    atIndex: index];







|







154
155
156
157
158
159
160
161
162
163
164
165
166
167
168

- removeNObjects: (size_t)nobjects
	 atIndex: (size_t)index
{
	OFObject **objs = [array cArray];
	size_t i, count = [array count];

	if (nobjects > count - index)
		@throw [OFOutOfRangeException newWithClass: isa];

	for (i = index; i < count && i < index + nobjects; i++)
		[objs[i] release];

	[array removeNItems: nobjects
		    atIndex: index];