X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fshow%2Fchat.pl;h=6e209e25dbd5645cccc6bad700b372b2b3e77ac8;hb=f47c97d80722ed7d1881afa7caa0e8d24b6b0a75;hp=3105c36b5ebb2a8f74bd9cff28a5139e4fa0e5aa;hpb=defc60f3e7fab9bb99d1c9f7b8bccc4ec37628d5;p=spider.git diff --git a/cmd/show/chat.pl b/cmd/show/chat.pl index 3105c36b..6e209e25 100644 --- a/cmd/show/chat.pl +++ b/cmd/show/chat.pl @@ -3,7 +3,7 @@ # # Copyright (c) 1998-2003 - Dirk Koopman G1TLH # -# $Id$ +# # my $self = shift; @@ -28,11 +28,18 @@ while ($f = shift @f) { # next field next if $to; } next if $who; - ($who) = $f =~ /^(\w+)/o; + if ($f !~ /^\d+/) { + ($who) = $f; + } +# ($who) = $f =~ /^(\w+)/o; } $to = 20 unless $to; $from = 0 unless $from; -@out = DXLog::print($from, $to, $main::systime, 'chat', $who); +if ($self->{_nospawn}) { + @out = DXLog::print($from, $to, $main::systime, 'chat', $who); +} else { + @out = $self->spawn_cmd("show/chat $cmdline", \&DXLog::print, args => [$from, $to, $main::systime, 'chat', $who]); +} return (1, @out);