<title>CURLOPT_CONV_FROM_NETWORK_FUNCTION man page</title>
<meta name="generator" content="roffit">
<STYLE type="text/css">
-pre {
- overflow: auto;
- margin: 0;
-}
-
-P.level0, pre.level0 {
+P.level0 {
padding-left: 2em;
}
-P.level1, pre.level1 {
+P.level1 {
padding-left: 4em;
}
-P.level2, pre.level2 {
+P.level2 {
padding-left: 6em;
}
<p class="level0"><a name="NAME"></a><h2 class="nroffsh">NAME</h2>
<p class="level0">CURLOPT_CONV_FROM_NETWORK_FUNCTION - convert data from network to host encoding <a name="SYNOPSIS"></a><h2 class="nroffsh">SYNOPSIS</h2>
-<p class="level0"><pre class="level0">
-#include <curl/curl.h>
-
-CURLcode conv_callback(char *ptr, size_t length);
-
-CURLcode curl_easy_setopt(CURL *handle, CURLOPT_CONV_FROM_NETWORK_FUNCTION,
- conv_callback);
-</pre>
+<p class="level0"><pre>
+<p class="level0">#include <curl/curl.h>
+ <p class="level0">CURLcode conv_callback(char *ptr, size_t length);
+ <p class="level0">CURLcode curl_easy_setopt(CURL *handle, CURLOPT_CONV_FROM_NETWORK_FUNCTION,
+ conv_callback);
+ </pre>
<a name="DESCRIPTION"></a><h2 class="nroffsh">DESCRIPTION</h2>
<p class="level0">Pass a pointer to your callback function, which should match the prototype shown above.
<p class="level0">Applies to non-ASCII platforms. <span Class="emphasis">curl_version_info(3)</span> will return the CURL_VERSION_CONV feature bit set if this option is provided.
<p class="level0"><span Class="bold">CURLOPT_CONV_FROM_NETWORK_FUNCTION</span> converts to host encoding from the network encoding. It is used when commands or ASCII data are received over the network.
<p class="level0">If you set a callback pointer to NULL, or don't set it at all, the built-in libcurl iconv functions will be used. If HAVE_ICONV was not defined when libcurl was built, and no callback has been established, conversion will return the CURLE_CONV_REQD error code.
<p class="level0">If HAVE_ICONV is defined, CURL_ICONV_CODESET_OF_HOST must also be defined. For example:
-<p class="level0"> #define CURL_ICONV_CODESET_OF_HOST "IBM-1047"
+<p class="level0"> #define CURL_ICONV_CODESET_OF_HOST "IBM-1047"
<p class="level0">The iconv code in libcurl will default the network and UTF8 codeset names as follows:
-<p class="level0"> #define CURL_ICONV_CODESET_OF_NETWORK "ISO8859-1"
-<p class="level0"> #define CURL_ICONV_CODESET_FOR_UTF8 "UTF-8"
+<p class="level0"> #define CURL_ICONV_CODESET_OF_NETWORK "ISO8859-1"
+<p class="level0"> #define CURL_ICONV_CODESET_FOR_UTF8 "UTF-8"
<p class="level0">You will need to override these definitions if they are different on your system. <a name="DEFAULT"></a><h2 class="nroffsh">DEFAULT</h2>
<p class="level0">NULL <a name="PROTOCOLS"></a><h2 class="nroffsh">PROTOCOLS</h2>
<p class="level0">FTP, SMTP, IMAP, POP3 <a name="EXAMPLE"></a><h2 class="nroffsh">EXAMPLE</h2>