Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^2: How to pass client connections to the worker threads?

by betterworld (Curate)
on Sep 10, 2008 at 12:30 UTC ( [id://710346]=note: print w/replies, xml ) Need Help??


in reply to Re: How to pass client connections to the worker threads?
in thread How to pass client connections to the worker threads?

The problem here is that CLIENTSOCKET is not autoflushing. You should add a line like CLIENTSOCKET->autoflush(1); somewhere between the open and the print. Note that for the other sockets this is not necessary because IO::Socket sets its sockets to autoflush automatically.

By the way, you don't need to store the socket in your filesystem (in /tmp/undomain). Instead, you can call socketpair before you create the thread.

Replies are listed 'Best First'.
Re^3: How to pass client connections to the worker threads?
by sunshine_august (Scribe) on Sep 11, 2008 at 02:19 UTC
    With CLIENTSOCKEt->autoflush(1), it works well, thx.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://710346]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (5)
As of 2024-04-19 15:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found