08-11-2023, 08:30 AM
Make sure that the byte arrays that you are transferring are initialized to zero before you start adding data to them. This will help to prevent the error from occurring if there is any leftover data from the previous operation in the byte array.