Do not interact with `self` if it was disposed
@@ -486,6 +486,7 @@ static int on_body(h2o_httpclient_t *client, const char *errstr)
if (errstr != NULL) {
self->generator_disposed = &generator_disposed;
on_body_on_close(self, errstr);
+ if (!generator_disposed)
self->generator_disposed = NULL;
}
if (!generator_disposed && !self->sending.inflight)
