ObjFW  Diff

Differences From Artifact [0dcfbd34b6]:

To Artifact [08fad4b779]:


448
449
450
451
452
453
454
455

456
457

458
459
460
461
462
463
464
448
449
450
451
452
453
454

455


456
457
458
459
460
461
462
463







-
+
-
-
+







	OFSocketAddress address;
	const struct sockaddr_in *addrIn;
	uint32_t addr;

	if (lastColon == OFNotFound)
		@throw [OFInvalidFormatException exception];

	IPv4 = [IPv6 substringWithRange:
	IPv4 = [IPv6 substringFromIndex: lastColon + 1];
	    OFMakeRange(lastColon + 1, IPv6.length - lastColon - 1)];
	IPv6 = [IPv6 substringWithRange: OFMakeRange(0, lastColon + 1)];
	IPv6 = [IPv6 substringToIndex: lastColon + 1];

	address = OFSocketAddressParseIPv4(IPv4, 0);
	addrIn = &address.sockaddr.in;
	addr = OFFromBigEndian32(addrIn->sin_addr.s_addr);

	return [IPv6 stringByAppendingString:
	    [OFString stringWithFormat: @"%x%02x:%x%02x",