@@ -40,11 +40,11 @@ Class of_http_request_tls_socket_class = Nil; static OF_INLINE void normalize_key(OFString *key) { - uint8_t *str = (uint8_t*)[key cString]; + uint8_t *str = (uint8_t*)[key UTF8String]; BOOL firstLetter = YES; while (*str != '\0') { if (!isalnum(*str)) { firstLetter = YES; @@ -260,11 +260,11 @@ [sock writeString: @"Content-Type: " @"application/x-www-form-urlencoded\r\n"]; if ([headers objectForKey: @"Content-Length"] == nil) [sock writeFormat: @"Content-Length: %d\r\n", - [queryString cStringLength]]; + [queryString UTF8StringLength]]; } [sock writeString: @"\r\n"]; /* Work around a bug in lighttpd, see above */ @@ -289,28 +289,28 @@ serverHeaders = [OFMutableDictionary dictionary]; while ((line = [sock readLine]) != nil) { OFString *key, *value; - const char *line_c = [line cString], *tmp; + const char *line_c = [line UTF8String], *tmp; if ([line isEqual: @""]) break; if ((tmp = strchr(line_c, ':')) == NULL) @throw [OFInvalidServerReplyException newWithClass: isa]; - key = [OFString stringWithCString: line_c - length: tmp - line_c]; + key = [OFString stringWithUTF8String: line_c + length: tmp - line_c]; normalize_key(key); do { tmp++; } while (*tmp == ' '); - value = [OFString stringWithCString: tmp]; + value = [OFString stringWithUTF8String: tmp]; if ((redirects > 0 && (status == 301 || status == 302 || status == 303) && [key isEqual: @"Location"]) && (redirectsFromHTTPSToHTTPAllowed || [scheme isEqual: @"http"] ||