powered by Jive Software

BUG: vCard avatar decoding produces bogus ByteArray

I don’t entirely understand the difference here, but after moving to com.hurlant.Base64 for avatar encoding and decoding the selected decode method does not work as expected. Instead of using** Base64.decodeToByteArray()**, we need to use Base64.decodeToByteArrayB(). Using the former seems to produce an unrenderable image.
vCard ByteArray Decode Patch.txt.zip (461 Bytes)

Function call changed in r11650.

Thanks for testing it.

This change makes the code incompatible with the as3crypto SWC on the google code page: http://code.google.com/p/as3crypto/downloads/list – this version (1.3) does not contain the ByteArrayB API method.

Karthik

It’s in the trunk: http://code.google.com/p/as3crypto/source/browse/trunk/as3crypto/src/com/hurlant /util/Base64.as and was added in revision 28 on June 4, 2009. The compiled SWC looks like it is only current as of June 2008 so you’ll need to check out the code and build it yourself if you require the change.

Ah right, I forgot to mention in my previous post:

I saw that it was in trunk, but I get compile errors when trying to build latest as3crypto sources in Flex Builder, which caused me to think that the trunk was not stable.

But now I see in the other thread someone has a working SWC with the trunk code, so I am probably wrong.

Karthik