istream-failure-at.c revision 25fb397382c6f7d39bfeee85774e7675f02bfb3c
/* Copyright (c) 2015 Dovecot authors, see the included COPYING file */
#include "lib.h"
#include "istream-private.h"
#include "istream-failure-at.h"
struct failure_at_istream {
struct istream_private istream;
char *error_string;
};
{
struct failure_at_istream *fstream =
(struct failure_at_istream *)stream;
}
static ssize_t
{
/* we already passed the wanted failure offset,
return error immediately. */
ret = -1;
} else {
/* return data up to the wanted failure offset and
on the next read() call return failure */
}
/* failure at EOF */
}
return ret;
}
struct istream *
const char *error_string)
{
struct failure_at_istream *fstream;
}
struct istream *
{
}