X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fbye.pl;h=41d3ee91af35a549d17dcfd57019b4c72ae82b75;hb=eac4538f1f78b3d014539dc548fc6322e8337429;hp=1fc73f66648a9251cb327d9c5923902adc20d308;hpb=6b6a8002929017b6d4217f68fa492a2d728ee1fe;p=spider.git diff --git a/cmd/bye.pl b/cmd/bye.pl index 1fc73f66..41d3ee91 100644 --- a/cmd/bye.pl +++ b/cmd/bye.pl @@ -1,9 +1,23 @@ # # the bye command # -# $Id$ +# # my $self = shift; -$self->state('bye'); +return (1, $self->msg('e5')) if $self->inscript; + +# log out text +if ($self->is_user && -e "$main::data/logout") { + open(I, "$main::data/logout") or confess; + my @in = ; + close(I); + $self->send_now('D', @in); + sleep(1); +} + +#$self->send_now('Z', ""); + +$self->disconnect; + return (1);