From: <co...@gm...> - 2007-03-25 01:11:57
|
Hi, Alex your patches were diff'ed against different root folders ("openobex-1.3-patch" and "openobex-1.3") and there were two patches for "apps/obex_test_client.c". I rearranged them so that now they comply with the "patch standard". I also rewrote "openobex-05-iconv-for-unicode" part, so that now it works with any locale, not necessarily UTF-8 (I've tested it with UTF-8 and KOI8-R and a Nokia phone with non-ASCII filenames). ----------------------- Original message: > These patches are a result of my attempts to make openobex 1.3 work with = my Sony Ericsson K300 phone, connected with an USB-to-serial adapter (DCU-1= 1 or so). These patches apply against the public tarball downloaded from op= enobex.triq.net ...... ...... > openobex-05-iconv-for-unicode.patch > This patch replaces the OBEX_CharToUnicode implementation with a more fun= ctional version which uses iconv for charset conversion. The previous imple= mentation is not useful for non-English locales, because it "converts" char= acters to Unicode by tacking a null byte to form a 16-bit big-endian value.= My phone has an images directory called "Im=E1genes" (that is, a string wi= th U+00E1 LATIN SMALL LETTER A WITH ACUTE). In my case, I was lucky because= the low byte of the codepoint happens to match the same symbol in the ISO-= 8859-1, so some trickery with the iconv command-line tool was enough. Now i= magine somebody in Japan with a directory name written in Kanji... Although= my patch hardcodes an assumption that the user is working in UTF-8 (with o= nly one fallback to ISO-8859-1), I think it is a better assumption than pur= e ASCII. > Please comment on these patches. > Alex Villac=EDs Lasso |