[PD-dev] socket gurus
Olaf Matthes
olaf.matthes at gmx.de
Tue Mar 2 17:15:17 CET 2004
august wrote:
>for example if I connect to http://66.28.68.70:8000/puredata.ogg and
>nothing is there at that server on that port, it returns non-0 with an
>error and everything is fine.
>
>But, if I try to connect with http://66.28.68.70:3200/puredata.ogg, it
>hangs completely.
>
Hi August,
what's the difference between the two URLs (in terms of server settings,
mountpoints and the like)? As far as I understand connect() can connect
to a socket in listening state and the socket we're connecting to has to
know what to do when it receives a connection request. In case you
accidentally try to connect to a socket meant to be used for
connectionless transfers (i.e. UDP and thus not in listening state) a
connect() call might block since it just doesn't get served from the
other side. This might also happen in case the server crashes...
The alarm / signal handler solution might be a way, although I never
used it myself.
Olaf
More information about the Pd-dev
mailing list