1
0
mirror of https://gitlab.com/libvirt/libvirt-python.git synced 2025-07-28 15:41:52 +03:00
Files
libvirt-python/libvirt-override-virStoragePool.py
Philipp Hahn ee5c856af7 Remove legacy libvirtError arguments
The fields have been deprecated in C with
git:f60dc0bc09f09c6817d6706a9edb1579a3e2b2b8

They are only passed to the libvirtError constructor, but not stored for
later or used anywhere else.

sed -ri '/raise libvirtError/s/, \w+=self(\._dom)?//' *.py

Signed-off-by: Philipp Hahn <hahn@univention.de>
2020-08-06 08:50:37 +02:00

12 lines
433 B
Python

def listAllVolumes(self, flags=0):
"""List all storage volumes and returns a list of storage volume objects"""
ret = libvirtmod.virStoragePoolListAllVolumes(self._o, flags)
if ret is None:
raise libvirtError("virStoragePoolListAllVolumes() failed")
retlist = list()
for volptr in ret:
retlist.append(virStorageVol(self._conn, _obj=volptr))
return retlist