#976: convert_from_utf8() broken --------------------------------------+------------------------------ Reporter: axeld | Owner: pulkomandy Type: bug | Status: assigned Priority: normal | Milestone: Unscheduled Component: Kits/libtextencoding.so | Version: R1/Development Resolution: | Keywords: Blocked By: | Has a Patch: 0 Platform: All | Blocking: --------------------------------------+------------------------------ Comment (by mmu_man): Indeed it's still a problem it seems... We can't put a pointer to a conv_struct unless we allow leaking them. One option is to keep opening/closing the context on each call, but copy back the istate/ostate member of the struct conv_struct that is returned by iconv_open(), depending on if encoding to or from a multibyte format. It seems to be the only member that actually maintains state, the rest being constant for each invocation and only depending on the to and from encoding setting. Unless istate and ostate are used at the same time... but probably not with those two calls. -- Ticket URL: <http://dev.haiku-os.org/ticket/976#comment:12> Haiku <http://dev.haiku-os.org> Haiku - the operating system.