Changed copystreaminfo.  allows writing of the header.