[Libwebsockets] license for plugins/protocol_lws_meta.c
andy at warmcat.com
Tue Mar 13 03:24:12 CET 2018
On 03/13/2018 09:21 AM, David Fletcher wrote:
> I've downloaded lws for the first time and I've started exploring the
> code. For my test, I'm compiling the test-server-v2.0 with statically-
> linked plugins; I'm using a C++ compiler. I've seen 2-3 places in each
> of the plugins .c files that need slight alteration to work with C++
> but, otherwise, I'm making good progress.
Well if they are easy to fix please send patches or diffs for them.
> I did see that the protocol_lws_meta.c file has an LGPL license while all
> the other plugin .c files licensed under Creative Commons CC0. Is
> there a reason why the one file has a different license?
I use CC0 where I expect people to cut and paste the code and use it as
the starting point of their own projects. For library code that isn't
like that, it's LGPL2. That plugin is library code you would either use
as-is or not at all.
lws_meta is going to be deprecated, because current master supports the
brand new ws-over-h2 stuff that has just appeared in Chrome Canary.
This lets ws flow multiplexed over the same tls connection as the http
stuff, which is much more efficient.
> The lws code seems very much state driven (with the states handled
> by switch statements)? Is there documentation that describes the
> various states? or maybe state diagrams available somewhere? Or, if
As a user, you don't need to know about or care about the internal state
machines and modes that are not in the public API.
If you mean the user callbacks, they are mainly informing you of
events... although there are a lot of them you can look at the
individual test plugins to see which ones are necessary for their
> anyone can point me to software that uses lws successfully, I'd like
> to study the code to see if I can get ideas for ways to use lws.
Previously you could go from the test apps, but in master there are new
"minimal" examples that just show how to do one thing each as simply as
For example the minimal http server:
is 50 SLOC that is very easy to understand.
> Thanks for making what is clearly a high-quality library freely available.
> Libwebsockets mailing list
> Libwebsockets at ml.libwebsockets.org
More information about the Libwebsockets