Lines Matching defs:string
24 * allocated string or NULL if an error occurred. */
70 char *curl_escape(const char *string, int inlength)
72 return curl_easy_escape(NULL, string, inlength);
76 char *curl_unescape(const char *string, int length)
78 return curl_easy_unescape(NULL, string, length, NULL);
81 char *curl_easy_escape(CURL *handle, const char *string, int inlength)
83 size_t alloc = (inlength?(size_t)inlength:strlen(string))+1;
98 in = *string;
129 string++;
136 * Curl_urldecode() URL decodes the given string.
141 * Returns a pointer to a malloced string in *ostring with length given in
142 * *olen. If length == 0, the length is assumed to be strlen(string).
146 const char *string, size_t length,
150 size_t alloc = (length?length:strlen(string))+1;
161 in = *string;
163 ISXDIGIT(string[1]) && ISXDIGIT(string[2])) {
167 hexstr[0] = string[1];
168 hexstr[1] = string[2];
182 string+=2;
191 string++;
199 /* store output string */
206 * Unescapes the given URL escaped string of given length. Returns a
207 * pointer to a malloced string with length given in *olen.
208 * If length == 0, the length is assumed to be strlen(string).
211 char *curl_easy_unescape(CURL *handle, const char *string, int length,
217 CURLcode res = Curl_urldecode(handle, string, inputlen, &str, &outputlen,