int (*init)(struct qcc *qcc);
int (*attach_ruqs)(struct qcs *qcs, void *ctx);
int (*decode_qcs)(struct qcs *qcs, void *ctx);
+ size_t (*snd_buf)(struct conn_stream *cs, struct buffer *buf, size_t count, int flags);
int (*finalize)(void *ctx);
};
return bidi_qcs_new(qcc, id);
}
-size_t qc_snd_buf(struct conn_stream *cs, struct buffer *buf, size_t count, int flags);
-
#endif /* USE_QUIC */
#endif /* _HAPROXY_MUX_QUIC_H */
.init = h3_init,
.attach_ruqs = h3_attach_ruqs,
.decode_qcs = h3_decode_qcs,
+ .snd_buf = h3_snd_buf,
.finalize = h3_finalize,
};
return 0;
}
+static size_t qc_snd_buf(struct conn_stream *cs, struct buffer *buf, size_t count, int flags)
+{
+ struct qcs *qcs = cs->ctx;
+ return qcs->qcc->app_ops->snd_buf(cs, buf, count, flags);
+}
+
/****************************************/
/* MUX initialization and instantiation */
/***************************************/
static const struct mux_ops qc_ops = {
.init = qc_init,
.wake = qc_wake,
- //.snd_buf = qc_snd_buf,
- .snd_buf = h3_snd_buf,
+ .snd_buf = qc_snd_buf,
.rcv_buf = qc_rcv_buf,
.subscribe = qc_subscribe,
.unsubscribe = qc_unsubscribe,