[248] in Coldmud discussion meeting
bind()
daemon@ATHENA.MIT.EDU (Tue May 17 22:54:52 1994
)
Date: Tue, 17 May 1994 20:51:56 -0600 (MDT)
From: the Lyncx <BRANDON@cc.usu.edu>
To: coldstuff@MIT.EDU
X-Vms-To: COLDSTUFF
<> bind() -- it doesn't work for more than 1 port
<
< Could you be more elaborate about this? Are you passing in the 'more
< than one part' as arguments to a single bind call (which is
< incorrect), or doing several bind() calls? If you're doing the
< latter, what do you mean by "it doesn't work"?
Sorry, I could have sworn I spoke about this once already. Ok, from the
manual:
bind(port, receiver)
[stuff]
I created a method on $sys called bind:
@program $sys.bind
arg port, obj;
if (caller() != $net)
throw(~perm, "Sender is not $net.");
(> bind(port, obj) <);
.
Called by $network (obviously). $net.bind:
@program $net.bind
arg port;
.perms(sender(), 'system);
$sys.bind(port, this());
.
Now, I eval $net.bind(12345) and receive:
! => Couldn't bind to port 12345.
! Thrown by function bind().
! ~bind: 0.bind (0) line: 5
! ~bind: $net.bind ($net) line: 4
! ~methoderr: $lynx.tmp_eval ($lynx) line: 5
! ~methoderr: $lynx.eval ($root) line: 16
Basically, I have tried all sorts of variations and different
objects/ports/etc. None work, and as far as I know none are being used
currently. Since it DOES obviously bind to the first port, I would assume this
is just a bug where it cannot bind to any more ports after the first one (?).
-Brandon/Lyncx-
(OH, and those two methods were quickies to test it out -- dont bother about
security with them).