some reason occasionally the byte[] was either being GC'd or moved
before libzip could write the data to the file. As a result when libzip
did try to write the data it gets an AccessViolation.
I tired Pinning the byte[] using a GCHandle but that did not seem to
do the trick. So the fallback is to use a MemoryStream and go through the
stream_callback system which we know works very well.
some reason occasionally the byte[] was either being GC'd or moved before libzip could write the data to the file. As a result when libzip did try to write the data it gets an AccessViolation.
I tired Pinning the byte[] using a GCHandle but that did not seem to do the trick. So the fallback is to use a MemoryStream and go through the stream_callback system which we know works very well.