Mmmh. Everything looked as if your code is *the solution*. Then came testing....
I still get these looong reads that completely timeout/block my cgi. Some connects work, a few times and then, nirvana. The cgi immediately returns when I kill the vlc process on the server side.
Somehow I wonder if it's really my read that doesn't return or some hickup on the vlc side.
- Any tips on how I could make my socket reading/connection more robust, so that it cares less about stale sockets? (socat never seems to care..)
- Should I issue the "logout" command vlc provides inside the rc session on each socket connect-command-read-"logout" cycle via my cgi (this cgi will never see much hits) So that vlc knows better: "this client is connecting, asking one thing, then disconnects"? (I know this is lsightly off-perl-topic)