Re: [Vala] I cannot get a simple websocket server working
- From: Marcin Lewandowski <marcin saepia net>
- To: ionut stoica <stoica ionut gmail com>
- Cc: "vala-list gnome org" <vala-list gnome org>
- Subject: Re: [Vala] I cannot get a simple websocket server working
- Date: Sun, 17 Dec 2017 12:09:06 -0500
Hello,
you need to do any operation that will increase ref count on your conn in websocket_handler. Otherwise it
will be freed as soon as the handler finishes. You can just call conn.ref() but it is no too smart, usually
better option is to keep e.g. a list of all open connections and adding it to the list should automatically
increase ref count.
m.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]