Re: Libiconv and errno (Win32)
| From: | Moriyoshi Koizumi | Date: | Sun, 18 May 2003 01:12:03 +0000 |
| Subject: | Re: Libiconv and errno (Win32) | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-1648@lists.php.net to get a copy of this message | ||
Hi,
"l0t3k" <cshmoove@bellsouth.net> wrote:
> im developing an extension under Win32 which links to libiconv, but i'm
> having a slight problem. i have a conversion which fails (iconv returns
> (size_t)-1), but errno is set to 0.
> any clues as to what is happening ?
>
> not that it matters, but the conversion is from ISO-8859-1 to UTF-16 .
That's most likely iconv.dll and your extension are linked to different
libc dlls since errno variable is both dll specific and thread specific.
It also fails to set a correct value to errno if your iconv.dll is
statically linked to MS libc.
Moriyoshi