[Libwebsockets] Q on protocol names

Michael Haberler mail17 at mah.priv.at
Sat Aug 9 22:36:42 CEST 2014


I'd like to have a single protocols structure, since I have a single callback only anyway, which cover http/s and ws/s

Ideally I'd inspect the ws protcol name the client desired, and upgrade to _that_ protocol, set an option in my private session structure (or deny altogether, modulo on protocol name)

is that something I could do? how?


thanks,
- Michael

since I just noted https://github.com/warmcat/libwebsockets/commit/a40760a2de74204c0c845315339b4613ce0bb439 - 
assuming a NULL protocol name on the first and only protocol structure, would that accept _any_ protocol name the client specified? my first attempt with a single NULL protocol name got me a busily looping server..






More information about the Libwebsockets mailing list