The functions will be used by next patch.
Signed-off-by: Lin Ma <lma(a)suse.com>
---
tools/virsh-pool.c | 10 ++--------
tools/virsh-pool.h | 11 +++++++++++
2 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/tools/virsh-pool.c b/tools/virsh-pool.c
index 34ed86152e..18f3839a4c 100644
--- a/tools/virsh-pool.c
+++ b/tools/virsh-pool.c
@@ -835,13 +835,7 @@ virshStoragePoolSorter(const void *a, const void *b)
virStoragePoolGetName(*pb));
}
-struct virshStoragePoolList {
- virStoragePoolPtr *pools;
- size_t npools;
-};
-
-static void
-virshStoragePoolListFree(struct virshStoragePoolList *list)
+void virshStoragePoolListFree(struct virshStoragePoolList *list)
{
size_t i;
@@ -855,7 +849,7 @@ virshStoragePoolListFree(struct virshStoragePoolList *list)
g_free(list);
}
-static struct virshStoragePoolList *
+struct virshStoragePoolList *
virshStoragePoolListCollect(vshControl *ctl,
unsigned int flags)
{
diff --git a/tools/virsh-pool.h b/tools/virsh-pool.h
index 219f0eea42..d7bacd8731 100644
--- a/tools/virsh-pool.h
+++ b/tools/virsh-pool.h
@@ -40,3 +40,14 @@ typedef struct virshPoolEventCallback virshPoolEventCallback;
extern virshPoolEventCallback virshPoolEventCallbacks[];
extern const vshCmdDef storagePoolCmds[];
+
+struct virshStoragePoolList {
+ virStoragePoolPtr *pools;
+ size_t npools;
+};
+
+struct virshStoragePoolList *
+virshStoragePoolListCollect(vshControl *ctl,
+ unsigned int flags);
+
+void virshStoragePoolListFree(struct virshStoragePoolList *list);
--
2.26.2