Extra character in WriteObject
I encrypted a JavaScript file as "dimsd.dat" with RandomAccessFile and then decrypted it as "dimsd.js",
Dim raf As RandomAccessFile
Dim raf1 As RandomAccessFile
raf.Initialize(File.DirRootExternal, "dimsd.dat", False)
fileIt = raf.ReadEncryptedObject(password, raf.CurrentPosition)
Log(fileIt)
raf1.Initialize(File.DirRootExternal, "dimsd.js", False)
raf1.WriteObject(fileIt, False, raf.CurrentPosition)
raf.Close
while using WriteObject to sdcard it has some extra characters in start of file as follows
original
function Question (qname, type, qstring, response, comment, corrects,explan,……..}
decrypted
aaafunction Question (qname, type, qstring, response, comment, corrects,explan,……..}
See some junk characters in start of file .
The Log(fileIt)is true copy but the written file on sdcard has above junk characters.
What can be the issue?
plz help