Signed-off-by: Felix Fietkau <nbd@openwrt.org>
if (!len) {
sf->fd.eof = true;
+ ustream_state_change(s);
+ ustream_fd_set_uloop(s, false);
return;
}
static bool __ustream_fd_poll(struct ustream_fd *sf, unsigned int events)
{
struct ustream *s = &sf->stream;
- struct uloop_fd *fd = &sf->fd;
bool more = false;
if (events & ULOOP_READ)
ustream_fd_set_uloop(s, false);
}
- if (!s->eof && fd->eof) {
- s->eof = true;
- ustream_fd_set_uloop(s, false);
- ustream_state_change(s);
- }
-
return more;
}