MINOR: hlua: Don't preform operations on a not connected socket
authorChristopher Faulet <cfaulet@haproxy.com>
Wed, 27 Sep 2023 15:22:41 +0000 (17:22 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 4 Oct 2023 13:34:00 +0000 (15:34 +0200)
commitee687aa18d6182373e3856951313711ddec7ed92
treedce5247ad77102712470cf241e60e7e27fb03f3b
parented9333827a6bf3c20e010485da12724992d2de51
MINOR: hlua: Don't preform operations on a not connected socket

There is nothing that prevent someone to create a lua socket and try to
receive or to write before the connection was established ot after the
shutdown was performed. The same is true when info about the socket are
retrieved.

It is not an issue because this will fail later. But now, we check the
socket is connected or not earlier. It is more effecient but it will be also
mandatory to fix issue with the lua sockets.
src/hlua.c