The following code:
say 'Hello world'~encodebase64
produces this output:
SGVsbG8gd29=bG==
but it should be:
SGVsbG8gd29ybGQ=
The inverse operation:
say 'SGVsbG8gd29ybGQ='~decodebase64
say 'SGVsbG8gd29=bG=='~decodebase64
gives:
Helowold
2 - say 'SGVsbG8gd29=bG=='~decodebase64
Error 93 running d:\home\salvador\decode64.rex line 2:
Incorrect call to method
Error 93.962: Invalid Base 64 encoded string.
parse version and parse source:
REXX-ooRexx_3.1(MT) 6.00 15 Aug 2006
WindowsNT COMMAND d:\home\salvador\decode64.rex
uname -a:
WindowsNT salvador_pc 1 5 x86
Salvador Parra Camacho (sparrac /at/ gmail \dot\ com)
Anonymous
Logged In: NO
The same happens with ooRexx 3.1 in Linux:
LINUX COMMAND /home/salvador/encode_decode.rex
REXX-ooRexx_3.1(MT) 6.00 15 Aug 2006
Linux multivac 2.6.12-9-386 #1 Mon Oct 10 13:14:36 BST
2005 i586 GNU/Linux
Salvador Parra Camacho (sparrac /at/ gmail \dot\ com)
PS. BIC means "Built-In Class".
Logged In: YES
user_id=931756
Fixed the encodebase64 string method in CVS and SVN.