[Libwebsockets] warning C4244: 'return' : conversion from 'lws_filepos_t' to 'size_t', possible loss of data

jon at keyonsec.com jon at keyonsec.com
Thu Apr 26 00:20:46 CEST 2018

Hello all,


I'm compiling websockets 2.4 in 32-bit Microsoft Visual C (v11) and noticed
this warning message. Can someone clarify if I should change some code to
alleviate the warning? Or should I typecast?


Function below. Please advise.








lws_get_peer_write_allowance(struct lws *wsi)


       if (wsi->role_ops->tx_credit)

              return wsi->role_ops->tx_credit(wsi); // This line is giving
me the warning


       return -1;


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://libwebsockets.org/pipermail/libwebsockets/attachments/20180425/c10ef838/attachment.html>

More information about the Libwebsockets mailing list