Hello everyone!
Using the following two different decoding methods will get different results
But in b4i, the result extracted by using stringutils.decodebase64 is correct
Is the function of stringutils.decodebase64 in b4a and b4i different?
(The above English is from translation software)
Using the following two different decoding methods will get different results
But in b4i, the result extracted by using stringutils.decodebase64 is correct
Is the function of stringutils.decodebase64 in b4a and b4i different?
(The above English is from translation software)
B4X:
Dim B64 As Base64
Dim su As StringUtils
Dim compress As CompressedStreams
Dim a As String="H4sIAP8sDWEA/4uuVjJQslIKcTIwMFTSUTKEsA2NgOyg5LwSJStDHSU3MMNIRykkMzcVKFKrA9EU6QHVYaRUGwsAcgHeqUkAAAA="
Dim d() As Byte
d=B64.DecodeStoB(a)
Log("OK Array Size:" & d.Length & "=" & d(0) & "," & d(1) & "," & d(2))
'OK Array Size:74=31,-117,8
d=compress.DecompressBytes(d,"gzip") '<- Normal decompression
Dim d() As Byte
d=su.DecodeBase64(a)
Log("Error Array Size:" & d.Length & "," & d(0) & "," & d(1) & "," & d(2))
'Error Array Size:73=91,123,34
d=compress.DecompressBytes(d,"gzip") '<-- Unable to unzip