Allocates a descriptor for a codeset conversion.
#include <iconv.h> iconv_t iconv_open ( const char *tocode, const char *fromcode);
(IN) Points to a string representing a codeset that the input string is to be converted to with the iconv function.
(IN) Points to a string representing a codeset that expresses the input string passed to the iconv function.
If successful, returns a codeset descriptor. Otherwise, returns -1 and sets errno to one of the following:
You use the descriptor returned by iconv_open in the iconv function to specify how you want a string converted from one codeset to another. The descriptor remains valid until closed with the iconv_close function.
The following strings can be used to specify a codeset in both the tocode and fromcode parameters.