#ifndef ISTREAM_SIZED_H
#define ISTREAM_SIZED_H
struct istream_sized_error_data {
/* Stream's current v_offset */
/* How many more bytes are being added within this read() */
/* What's the original wanted size. */
/* TRUE if we're at EOF now */
bool eof;
};
typedef const char *
void *context);
/* Assume that input stream is exactly the given size. If the stream is too
small, fail with stream_errno=EPIPE. If stream is too large, fail with
stream_errno=EINVAL. */
/* Like i_stream_create_sized*(), but allow input stream's size to be larger. */
/* Same as i_stream_create_sized(), but set the error message via the
callback. */
struct istream *
void *context);
#endif