]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: storage: Add helper to determine whether storage is local
authorPeter Krempa <pkrempa@redhat.com>
Wed, 25 Jun 2014 11:47:32 +0000 (13:47 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Fri, 4 Jul 2014 08:59:51 +0000 (10:59 +0200)
commitea43f5f9b3a3899704d01aabfd3184fd0ef5c076
tree6bd7c8adfe1ef4619eae00622a71497872231eca
parent97e3397cde970c95c1e66eb1f52f133d568bd4e4
util: storage: Add helper to determine whether storage is local

There's a lot of places where we skip doing actions based on the
locality of given storage type. The usual pattern is to skip it if:

virStorageSourceGetActualType(src) == VIR_STORAGE_TYPE_NETWORK

Add a simple helper to simplify the pattern to
virStorageSourceIsLocalStorage(src)
src/libvirt_private.syms
src/util/virstoragefile.c
src/util/virstoragefile.h