Index: src/OFArchiveIRIHandler.m ================================================================== --- src/OFArchiveIRIHandler.m +++ src/OFArchiveIRIHandler.m @@ -91,14 +91,13 @@ if (pos == OFNotFound) @throw [OFInvalidArgumentException exception]; archiveIRI = [OFIRI IRIWithString: - [percentEncodedPath substringWithRange: OFMakeRange(0, pos)] + [percentEncodedPath substringToIndex: pos] .stringByRemovingPercentEncoding]; - path = [percentEncodedPath substringWithRange: - OFMakeRange(pos + 1, percentEncodedPath.length - pos - 1)] + path = [percentEncodedPath substringFromIndex: pos + 1] .stringByRemovingPercentEncoding; if ([scheme isEqual: @"lha"]) { OFLHAArchive *archive = [OFLHAArchive archiveWithIRI: archiveIRI mode: mode]; Index: src/OFMutableZooArchiveEntry.m ================================================================== --- src/OFMutableZooArchiveEntry.m +++ src/OFMutableZooArchiveEntry.m @@ -144,16 +144,14 @@ size_t lastSlash; lastSlash = [fileName rangeOfString: @"/" options: OFStringSearchBackwards].location; if (lastSlash != OFNotFound) { - _fileName = [[fileName substringWithRange: OFMakeRange( - lastSlash + 1, fileName.length - lastSlash - 1)] copy]; + _fileName = [[fileName substringFromIndex: lastSlash + 1] copy]; [oldFileName release]; - _directoryName = [[fileName substringWithRange: - OFMakeRange(0, lastSlash)] copy]; + _directoryName = [[fileName substringToIndex: lastSlash] copy]; [oldDirectoryName release]; } else { _fileName = [fileName copy]; [oldFileName release]; Index: src/OFSocket.m ================================================================== --- src/OFSocket.m +++ src/OFSocket.m @@ -450,13 +450,12 @@ uint32_t addr; if (lastColon == OFNotFound) @throw [OFInvalidFormatException exception]; - IPv4 = [IPv6 substringWithRange: - OFMakeRange(lastColon + 1, IPv6.length - lastColon - 1)]; - IPv6 = [IPv6 substringWithRange: OFMakeRange(0, lastColon + 1)]; + IPv4 = [IPv6 substringFromIndex: lastColon + 1]; + IPv6 = [IPv6 substringToIndex: lastColon + 1]; address = OFSocketAddressParseIPv4(IPv4, 0); addrIn = &address.sockaddr.in; addr = OFFromBigEndian32(addrIn->sin_addr.s_addr);