1curl_easy_unescape(3)           libcurl Manual           curl_easy_unescape(3)
2
3
4

NAME

6       curl_easy_unescape - URL decodes the given string
7

SYNOPSIS

9       #include <curl/curl.h>
10
11       char  *curl_easy_unescape(  CURL  *curl,  char *url, int inlength , int
12       *outlength );
13

DESCRIPTION

15       This function converts the given URL encoded input string to  a  "plain
16       string" and returns that in an allocated memory area. All input charac‐
17       ters that are URL encoded (%XX where XX is a two-digit hexadecimal num‐
18       ber) are converted to their binary versions.
19
20       If  the  length argument is set to 0 (zero), curl_easy_unescape(3) will
21       use strlen() on the input url string to find out the size.
22
23       If outlength is non-NULL, the function will write  the  length  of  the
24       returned  string  in  the  integer it points to. This allows an escaped
25       string containing %00 to still get used properly after unescaping.
26
27       You must curl_free(3) the returned string when you're done with it.
28

AVAILABILITY

30       Added in 7.15.4 and replaces the old curl_unescape(3) function.
31

RETURN VALUE

33       A pointer to a zero terminated string or NULL if it failed.
34

SEE ALSO

36       curl_easy_escape(3), curl_free(3), RFC 2396
37
38
39
40libcurl 7.15.4                   7 April 2006            curl_easy_unescape(3)
Impressum