<div dir="ltr"><span style="font-size:12.8px">I try this as Andy suggested all of this in the server . under the case LWS_CALLBACK_RECEIVE:</span><div style="font-size:12.8px"><div><br></div><div>long wsi_adress = &wsi;</div><div>lwsl_notice("string recived from client:%lu\n", wsi_adress);</div></div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">i tried to invoke several ws requests  from different browsers </div><div style="font-size:12.8px">but it always gave me the same value . am i do it currently of you meant to something totally different ?</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Jun 12, 2016 at 12:28 PM, Meir Yanovich <span dir="ltr"><<a href="mailto:meiry242@gmail.com" target="_blank">meiry242@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 .8ex;border-left:1px #ccc solid;border-right:1px #ccc solid;padding-left:1ex;padding-right:1ex"><div dir="ltr">I try this as Andy suggested all of this in the server . under the case LWS_CALLBACK_RECEIVE:<div><div><br></div><div>long wsi_adress = &wsi;</div><div>lwsl_notice("string recived from client:%lu\n", wsi_adress);</div></div><div><br></div><div>i tried to invoke several ws requests  from different browsers </div><div>but it always gave me the same value . am i do it currently of you meant to something totally different ?</div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Jun 12, 2016 at 11:37 AM, Meir Yanovich <span dir="ltr"><<a href="mailto:meiry242@gmail.com" target="_blank">meiry242@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 .8ex;border-left:1px #ccc solid;border-right:1px #ccc solid;padding-left:1ex;padding-right:1ex"><div dir="auto"><div><div style="direction:ltr">Yes it is server side </div><div style="direction:ltr">You mean the wsi pointer long ? </div><div style="direction:ltr">Or what ? </div><div style="direction:ltr"><br></div><div style="text-align:left;direction:ltr"><br></div></div><div style="direction:rtl;text-align:right"><br>‫ב-12 ביוני 2016, בשעה 10:52, ‏‏Andy Green ‏<<a href="mailto:andy@warmcat.com" target="_blank">andy@warmcat.com</a>> כתב/ה:‬<br><br></div><div><div><div><span></span><br><span></span><br><span>On June 12, 2016 3:23:19 PM GMT+08:00, Meir Yanovich <<a href="mailto:meiry242@gmail.com" target="_blank">meiry242@gmail.com</a>> wrote:</span><br><blockquote type="cite"><span>Yes this is the case i want it to be lookup key .</span><br></blockquote><span></span><br><span>If we're talking about the server, the port the socket is connected to on the server side will uniquely identify it, at least while the connection is connected.</span><br><span></span><br><span>But the wsi will also do that... again while it's connected.</span><br><span></span><br><span>Or just increment a magic static index every ESTABLISHED callback and tag the per-connection struct with that.  But if that's all then your map will only grow.</span><br><span></span><br><span>So IIUI you have no choice but track the connection lifecycle, if the type of the id is 'long' then wsi is as good as anything.</span><br><span></span><br><span>-Andy</span><br><span></span><br><blockquote type="cite"><span>On Sun, Jun 12, 2016 at 10:01 AM, Edwin van den Oetelaar <</span><br></blockquote><blockquote type="cite"><span><a href="mailto:oetelaar.automatisering@gmail.com" target="_blank">oetelaar.automatisering@gmail.com</a>> wrote:</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><blockquote type="cite"><span>On Sun, Jun 12, 2016 at 8:12 AM, Meir Yanovich <<a href="mailto:meiry242@gmail.com" target="_blank">meiry242@gmail.com</a>></span><br></blockquote></blockquote><blockquote type="cite"><span>wrote:</span><br></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>I want to keep it as key in hash map</span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>(hash map is implementation detail)</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>So solve what problem?</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span>To find the lookup up later and use the connection for a reply maybe?</span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>‫ב-12 ביוני 2016, בשעה 06:18, ‏‏Bruce Perens ‏<<a href="mailto:bruce@perens.com" target="_blank">bruce@perens.com</a>></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><span>כתב/ה:‬</span><br></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>On Sat, Jun 11, 2016 at 2:33 PM, Andy Green <<a href="mailto:andy@warmcat.com" target="_blank">andy@warmcat.com</a>></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><span>wrote:</span><br></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>Why are you asking on the lws list about some socket.io-specific</span><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><span>detail?</span><br></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>Just say what you want to do with it, once you have it, and we can</span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>probably give you a portable way. :-)</span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>_______________________________________________</span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span>Libwebsockets mailing list</span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span><a href="mailto:Libwebsockets@ml.libwebsockets.org" target="_blank">Libwebsockets@ml.libwebsockets.org</a></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span><a href="http://libwebsockets.org/mailman/listinfo/libwebsockets" target="_blank">http://libwebsockets.org/mailman/listinfo/libwebsockets</a></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><span></span><br></blockquote></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>------------------------------------------------------------------------</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>_______________________________________________</span><br></blockquote><blockquote type="cite"><span>Libwebsockets mailing list</span><br></blockquote><blockquote type="cite"><span><a href="mailto:Libwebsockets@ml.libwebsockets.org" target="_blank">Libwebsockets@ml.libwebsockets.org</a></span><br></blockquote><blockquote type="cite"><span><a href="http://libwebsockets.org/mailman/listinfo/libwebsockets" target="_blank">http://libwebsockets.org/mailman/listinfo/libwebsockets</a></span><br></blockquote><span></span><br></div></div></div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>