X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Funset%2Fhere.pl;h=59b2080a3197d8131a0d13a31bf82ec5d9fae9b1;hb=refs%2Fheads%2Fspider;hp=e69de29bb2d1d6434b8b29ae775ad8c2e48c5391;hpb=6b6a8002929017b6d4217f68fa492a2d728ee1fe;p=spider.git diff --git a/cmd/unset/here.pl b/cmd/unset/here.pl index e69de29b..59b2080a 100644 --- a/cmd/unset/here.pl +++ b/cmd/unset/here.pl @@ -0,0 +1,35 @@ +# +# unset the here flag +# +# Copyright (c) 1998 - Dirk Koopman +# +# +# + +my ($self, $line) = @_; +my @args = split /\s+/, $line; +my $call; +my @out; + +@args = $self->call if (!@args || $self->priv < 9); + +foreach $call (@args) { + $call = uc $call; + my $dxchan = DXChannel::get($call); + if ($dxchan) { + $dxchan->here(0); + push @out, $self->msg('hereu', $call); + my $ref = Route::User::get($call); + $ref = Route::Node::get($call) unless $ref; + if ($ref) { + $ref->here(0); + my $s = DXProt::pc24($ref); + DXProt::eph_dup($s); + DXChannel::broadcast_all_nodes($s, $main::me) ; + } + } else { + push @out, $self->msg('e3', "Unset Here", $call); + } +} + +return (1, @out);