Attempts to write the source stream to the destination stream.
source stream
destination stream
the number of bytes written or %-1 on fail.