diff options
| author | Matthew Ruffell <matthew.ruffell@canonical.com> | 2019-03-28 15:43:21 -0400 |
|---|---|---|
| committer | Steve Dickson <steved@redhat.com> | 2019-03-28 15:43:21 -0400 |
| commit | c4c14011b70375050d7bba7c57e2eaf4c715dc7c (patch) | |
| tree | 520c0881eec483297ac9d5301ac82b592c625667 | |
| parent | 3dea72bed72bb6ac35f11de13c9154c2ecca8223 (diff) | |
| download | nfs-utils-c4c14011b70375050d7bba7c57e2eaf4c715dc7c.tar.gz | |
nfsiostat: replace 'list' reserved word
list is a reserved word in python and should not be used as a variable
name. Changing list to devicelist for list_nfs_mounts()
Fixes: https://bugs.launchpad.net/ubuntu/+source/nfs-utils/+bug/1821261
Signed-off-by: Matthew Ruffell <matthew.ruffell@canonical.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
| -rw-r--r-- | tools/nfs-iostat/nfs-iostat.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/nfs-iostat/nfs-iostat.py b/tools/nfs-iostat/nfs-iostat.py index 7cbe543..dec0e86 100644 --- a/tools/nfs-iostat/nfs-iostat.py +++ b/tools/nfs-iostat/nfs-iostat.py @@ -493,20 +493,20 @@ def list_nfs_mounts(givenlist, mountstats): return a full list if the given list is empty - may return an empty list if none found """ - list = [] + devicelist = [] if len(givenlist) > 0: for device in givenlist: stats = DeviceData() stats.parse_stats(mountstats[device]) if stats.is_nfs_mountpoint(): - list += [device] + devicelist += [device] else: for device, descr in mountstats.items(): stats = DeviceData() stats.parse_stats(descr) if stats.is_nfs_mountpoint(): - list += [device] - return list + devicelist += [device] + return devicelist def iostat_command(name): """iostat-like command for NFS mount points |
