Sorry to say I can't help you with the perl module, but I have a suggestion for testing. When dealing with sockets, you can use netcat to test your code. Netcat can act as client or server and gives you more finite control over what's being sent without modifying code.
Comment on Re: FCGI.pm client sockets: INET vs. UNIX