On Wed, Aug 08, 2001 at 02:57:52PM +1000, [EMAIL PROTECTED] wrote:
> 
> Up front I wish to apologise for my lack of understanding of sockets and
> socket programming. The only time I've ever read anything about them is in
> the POE docs. For those of you who are offended by newbie cluelessness
> please stop reading...
> 
> I am currently wishing to explore POE. My problem is that my ports have been
> turned off by the sysadmin in their infinite wisdom and I could never tell
> them I was looking at POE let alone knew some perl (my day job is unrelated
> to programming) - but that's another story...
> 
> The only socket type POE sample or test that worked was the udp.perl sample
> which relied on IO::Socket rather than a socketfactory. Everything else
> would give me a SEGV or the client would report unknown error number 10022
> which I presume is "you cant do sockets here laddie". After digging around
> for a long while I found that the socketfactory would fall over on a
> C<connect> call. What could still work was C<send> and C<recv> calls. So my
> question is shouldn't it be possible for a socketfactory to work with the
> udp protocol despite not being able to connect. They are "connectionless"
> sockets after all.


There should be no problem with UDP sockets and SocketFactory.  In
fact, t/13_udp.t uses SocketFactory, and test results from Windows
users say it passes ok.  The socketfactory.perl example in the samples
directory also tries UDP sockets, but it uses UNIX sockets too, and
that kills the whole program on Windows.  You could comment out the
UNIX socket stuff, and it probably would work for you.

I'm assuming you mean Windows, by the way.

10022 is "Invalid argument." in WinSock-ese, and it normally doesn't
try to connect() for UDP sockets.  I understand, though, that
connect() does something for UDP (sets the default sendto address?).
Maybe Windows doesn't support that.

-- Rocco Caputo / [EMAIL PROTECTED] / poe.perl.org / poe.sourceforge.net

Reply via email to