[Yum-devel] [PATCH 2/2] use xreadlines() not readline()

Seth Vidal skvidal at fedoraproject.org
Mon Dec 21 22:39:06 UTC 2009



On Fri, 11 Dec 2009, Ville Skyttä wrote:

> On Thursday 10 December 2009, Seth Vidal wrote:
>> ---
>>  yum/misc.py |    2 +-
>>  1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/yum/misc.py b/yum/misc.py
>> index 98e25ff..6c76dd1 100644
>> --- a/yum/misc.py
>> +++ b/yum/misc.py
>> @@ -896,7 +896,7 @@ def get_open_files(pid):
>>      except (IOError, OSError), e:
>>          return files
>>
>> -    for line in maps.readline():
>> +    for line in maps.xreadlines():
>
> Wouldn't simply
>
>       for line in maps:
>
> do the same thing?  FWIW xreadlines no longer exists in Python 3.

didn't realize about python3.

fixed and patch submitted.

thanks
-sv


More information about the Yum-devel mailing list