I have an application which sends SOAP message over JMS (TIBCO EMS). This SOAP message contains a binary attachment (swa). I have written following Java code to extract the binary attachment but when I write this attachment to a file, the file format is corrupted and size of the output file generated is different from what is sent as an input. Can you please help in finding out what is wrong with this code?
Thanks for your help!
subject: Unable to extract binary attachment correctly