BUG/MEDIUM: stream: Make sure to unsubscribe before si_release_endpoint.

Make sure we unsubscribe from events before si_release_endpoint destroys
the conn_stream, or it will be never called. To do so, move the call to
unsubscribe to si_release_endpoint() directly.

This is 1.9-specific and shouldn't be backported.
diff --git a/include/proto/stream_interface.h b/include/proto/stream_interface.h
index e83187b..95a8e23 100644
--- a/include/proto/stream_interface.h
+++ b/include/proto/stream_interface.h
@@ -169,8 +169,12 @@
 	if (!si->end)
 		return;
 
-	if ((cs = objt_cs(si->end)))
+	if ((cs = objt_cs(si->end))) {
+		if (si->wait_event.wait_reason != 0)
+			cs->conn->mux->unsubscribe(cs, si->wait_event.wait_reason,
+			    &si->wait_event);
 		cs_destroy(cs);
+	}
 	else if ((appctx = objt_appctx(si->end))) {
 		if (appctx->applet->release && si->state < SI_ST_DIS)
 			appctx->applet->release(appctx);