[android-developers] Re: Why String \0 is converted to [65533,65533]

2009-11-16 Thread fadden
On Nov 14, 5:58 am, Joes joyj...@gmail.com wrote: While I'm programming the Android SMTP code,I met a confused problem with code similar as the following:     String str= \0 username \0 passwrd; After executed the code, I found \0 is intepreted as two undisplayable char. I ran a quick test

[android-developers] Re: Why String \0 is converted to [65533,65533]

2009-11-15 Thread PJ
I assume that this is Java code and not C code. Is that right? Are you sure that you posted your code correctly? When I try what you've done, I get an IndexOutOfBoundsException when executing sZero.charAt(1), which is what I would expect. Also, are you sure you're getting 65533 and not 65535?

[android-developers] Re: Why String \0 is converted to [65533,65533]

2009-11-14 Thread Andrei
just a guess that u want to do this instead \\0 On Nov 14, 8:58 am, Joes joyj...@gmail.com wrote: All, While I'm programming the Android SMTP code,I met a confused problem with code similar as the following:     String str= \0 username \0 passwrd; After executed the code, I found \0 is

[android-developers] Re: Why String \0 is converted to [65533,65533]

2009-11-14 Thread Joes
I just wanna know, with what condition can cause this issue. I think it's probably because of the charset setup which is controlled by makefile or something else. I need a direction to look into. Thanks On Nov 14, 9:18 am, Andrei gml...@gmail.com wrote: just a guess that u want to do this