MINOR: mux: register the pass-through mux for any ALPN string

The pass-through mux is the fallback used on any incoming connection
unless another mux claims the ALPN name and the proxy mode. Thus mux_pt
registers ALPN token "" (empty name) which catches everything.
This commit is contained in:
Willy Tarreau 2017-09-21 19:43:21 +02:00
parent 2386be64ba
commit f64908294c

View File

@ -59,3 +59,13 @@ const struct mux_ops mux_pt_ops = {
.wake = mux_pt_wake,
.name = "PASS",
};
/* ALPN selection : default mux has empty name */
static struct alpn_mux_list alpn_mux_pt =
{ .token = IST(""), .mode = ALPN_MODE_ANY, .mux = &mux_pt_ops };
__attribute__((constructor))
static void __mux_pt_init(void)
{
alpn_register_mux(&alpn_mux_pt);
}