Destruction

In common with most other MuPDF objects, fz_streams are reference counted.

As such additional references can be taken using fz_keep_stream and they can be destroyed using fz_drop_stream.

Note that care must be taken not to use fz_stream objects simultaneously in more than one thread. Not only does the act of reading in one thread upset the point at which the next read will happen in another thread, no protection is provided to make operations atomic - thus the internal data can become corrupted and cause crashes.