[PerlChina] 答复: 我怎么发不了邮件到mail list

Steven Zhu stevenzyk at gmail.com
Sun Mar 23 19:33:23 PDT 2008


请教一下我这个线程有关闭掉吗?不太理解perl的多线程
我这样的话,join能够关闭线程吗?


while(1)
{
    $MySocket->recv($text,128);
    if($text =~ 'username')
    {
        $tempcount = 0;
        @threads[$tempcount]=threads->new(\&start_thread,$MySocket);
        $tempcount++;
        print "\nReceived message '", $text,"'\n";
    }
}

 foreach my $thread (@threads) {
 print "end\n";
 $thread->join();
}
sub start_thread{
      执行程序;
}



在08-3-23,bruce cheng <bruce1914 at gmail.com> 写道:
>
> 发邮件列表自己是收不到的。
>
> 不知道能不能改进下。
>
> > -----邮件原件-----
> > 发件人: china-pm-bounces+bruce1914=gmail.com at pm.org
> > [mailto:china-pm-bounces+bruce1914=gmail.com at pm.org] 代表 purl lamp
> > 发送时间: 2008年3月23日 18:16
> > 收件人: china-pm at pm.org
> > 主题: Re: [PerlChina] 我怎么发不了邮件到mail list
> >
> > you have made it :D
> >
> > 在 08-3-23,gary.jsz<gary.jsz at gmail.com> 写道:
> > >
> > >
> > > 奇怪,try again
> > >
> > >  ________________________________
> > >
> > > 蒋士竹
> > > _______________________________________________
> > >  China-pm mailing list
> > >  China-pm at pm.org
> > >  http://mail.pm.org/mailman/listinfo/china-pm
> > >
> > _______________________________________________
> > China-pm mailing list
> > China-pm at pm.org
> > http://mail.pm.org/mailman/listinfo/china-pm
>
> _______________________________________________
> China-pm mailing list
> China-pm at pm.org
> http://mail.pm.org/mailman/listinfo/china-pm




-- 
BR
Steven.zhu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.pm.org/pipermail/china-pm/attachments/20080324/0e20563f/attachment.html 


More information about the China-pm mailing list