Arthur,

If you mean to add the second readline then the script already has that, I'd
shortened the script for clarity.

The problem is that it doesn;'t get past the first readline.

Someone has responded off-list so I'll try his suggestions first before
anymore questions.

Thanks anyway.

Phil

----- Original Message -----
From: Arthur Lee
To: Phil Harris ; [EMAIL PROTECTED]
Sent: Friday, July 06, 2001 7:29 AM
Subject: Re: popen usage


Perhaps it should have been the following? :

1:    stdin=os.popen('tail -f somefile')
2:    logline=re.compile('(.*?).*?- - \[(.*?)\] "(.*?) (.*?)" (.*?)
(.*?)"(.*?)" (.*?)".*')
3:    a=stdin.readline()
4:    print a
5:    while a:
6:        g=logline.search(a)
7:        if not g: continue
8:        a=stdin.readline()


Regards,
Arthur

_______________________________________________
ActivePython mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/activepython

Reply via email to