mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
virsh: Fix internal naming of some blockjob commands
The variable names for the options and information about a command should have an underscore in places where the virsh command has a hyphen. The function callback name should capitalize the letter after the hyphen. This was not used in 'blockcommit', 'blockcopy', 'blockjob', 'blockpull', and 'blockresize' commands. Signed-off-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
f9159efec8
commit
ca9aac53d3
@ -1874,7 +1874,7 @@ virshBlockJobWait(virshBlockJobWaitDataPtr data)
|
|||||||
/*
|
/*
|
||||||
* "blockcommit" command
|
* "blockcommit" command
|
||||||
*/
|
*/
|
||||||
static const vshCmdInfo info_block_commit[] = {
|
static const vshCmdInfo info_blockcommit[] = {
|
||||||
{.name = "help",
|
{.name = "help",
|
||||||
.data = N_("Start a block commit operation.")
|
.data = N_("Start a block commit operation.")
|
||||||
},
|
},
|
||||||
@ -1884,7 +1884,7 @@ static const vshCmdInfo info_block_commit[] = {
|
|||||||
{.name = NULL}
|
{.name = NULL}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const vshCmdOptDef opts_block_commit[] = {
|
static const vshCmdOptDef opts_blockcommit[] = {
|
||||||
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
||||||
{.name = "path",
|
{.name = "path",
|
||||||
.type = VSH_OT_DATA,
|
.type = VSH_OT_DATA,
|
||||||
@ -1952,7 +1952,7 @@ static const vshCmdOptDef opts_block_commit[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
cmdBlockCommit(vshControl *ctl, const vshCmd *cmd)
|
cmdBlockcommit(vshControl *ctl, const vshCmd *cmd)
|
||||||
{
|
{
|
||||||
virDomainPtr dom = NULL;
|
virDomainPtr dom = NULL;
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
@ -2099,7 +2099,7 @@ cmdBlockCommit(vshControl *ctl, const vshCmd *cmd)
|
|||||||
/*
|
/*
|
||||||
* "blockcopy" command
|
* "blockcopy" command
|
||||||
*/
|
*/
|
||||||
static const vshCmdInfo info_block_copy[] = {
|
static const vshCmdInfo info_blockcopy[] = {
|
||||||
{.name = "help",
|
{.name = "help",
|
||||||
.data = N_("Start a block copy operation.")
|
.data = N_("Start a block copy operation.")
|
||||||
},
|
},
|
||||||
@ -2109,7 +2109,7 @@ static const vshCmdInfo info_block_copy[] = {
|
|||||||
{.name = NULL}
|
{.name = NULL}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const vshCmdOptDef opts_block_copy[] = {
|
static const vshCmdOptDef opts_blockcopy[] = {
|
||||||
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
||||||
{.name = "path",
|
{.name = "path",
|
||||||
.type = VSH_OT_DATA,
|
.type = VSH_OT_DATA,
|
||||||
@ -2192,7 +2192,7 @@ static const vshCmdOptDef opts_block_copy[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
cmdBlockCopy(vshControl *ctl, const vshCmd *cmd)
|
cmdBlockcopy(vshControl *ctl, const vshCmd *cmd)
|
||||||
{
|
{
|
||||||
virDomainPtr dom = NULL;
|
virDomainPtr dom = NULL;
|
||||||
const char *dest = NULL;
|
const char *dest = NULL;
|
||||||
@ -2415,7 +2415,7 @@ cmdBlockCopy(vshControl *ctl, const vshCmd *cmd)
|
|||||||
/*
|
/*
|
||||||
* "blockjob" command
|
* "blockjob" command
|
||||||
*/
|
*/
|
||||||
static const vshCmdInfo info_block_job[] = {
|
static const vshCmdInfo info_blockjob[] = {
|
||||||
{.name = "help",
|
{.name = "help",
|
||||||
.data = N_("Manage active block operations")
|
.data = N_("Manage active block operations")
|
||||||
},
|
},
|
||||||
@ -2425,7 +2425,7 @@ static const vshCmdInfo info_block_job[] = {
|
|||||||
{.name = NULL}
|
{.name = NULL}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const vshCmdOptDef opts_block_job[] = {
|
static const vshCmdOptDef opts_blockjob[] = {
|
||||||
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
||||||
{.name = "path",
|
{.name = "path",
|
||||||
.type = VSH_OT_DATA,
|
.type = VSH_OT_DATA,
|
||||||
@ -2609,7 +2609,7 @@ virshBlockJobAbort(virDomainPtr dom,
|
|||||||
|
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
cmdBlockJob(vshControl *ctl, const vshCmd *cmd)
|
cmdBlockjob(vshControl *ctl, const vshCmd *cmd)
|
||||||
{
|
{
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
bool raw = vshCommandOptBool(cmd, "raw");
|
bool raw = vshCommandOptBool(cmd, "raw");
|
||||||
@ -2658,7 +2658,7 @@ cmdBlockJob(vshControl *ctl, const vshCmd *cmd)
|
|||||||
/*
|
/*
|
||||||
* "blockpull" command
|
* "blockpull" command
|
||||||
*/
|
*/
|
||||||
static const vshCmdInfo info_block_pull[] = {
|
static const vshCmdInfo info_blockpull[] = {
|
||||||
{.name = "help",
|
{.name = "help",
|
||||||
.data = N_("Populate a disk from its backing image.")
|
.data = N_("Populate a disk from its backing image.")
|
||||||
},
|
},
|
||||||
@ -2668,7 +2668,7 @@ static const vshCmdInfo info_block_pull[] = {
|
|||||||
{.name = NULL}
|
{.name = NULL}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const vshCmdOptDef opts_block_pull[] = {
|
static const vshCmdOptDef opts_blockpull[] = {
|
||||||
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
||||||
{.name = "path",
|
{.name = "path",
|
||||||
.type = VSH_OT_DATA,
|
.type = VSH_OT_DATA,
|
||||||
@ -2711,7 +2711,7 @@ static const vshCmdOptDef opts_block_pull[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
cmdBlockPull(vshControl *ctl, const vshCmd *cmd)
|
cmdBlockpull(vshControl *ctl, const vshCmd *cmd)
|
||||||
{
|
{
|
||||||
virDomainPtr dom = NULL;
|
virDomainPtr dom = NULL;
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
@ -2804,7 +2804,7 @@ cmdBlockPull(vshControl *ctl, const vshCmd *cmd)
|
|||||||
/*
|
/*
|
||||||
* "blockresize" command
|
* "blockresize" command
|
||||||
*/
|
*/
|
||||||
static const vshCmdInfo info_block_resize[] = {
|
static const vshCmdInfo info_blockresize[] = {
|
||||||
{.name = "help",
|
{.name = "help",
|
||||||
.data = N_("Resize block device of domain.")
|
.data = N_("Resize block device of domain.")
|
||||||
},
|
},
|
||||||
@ -2814,7 +2814,7 @@ static const vshCmdInfo info_block_resize[] = {
|
|||||||
{.name = NULL}
|
{.name = NULL}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const vshCmdOptDef opts_block_resize[] = {
|
static const vshCmdOptDef opts_blockresize[] = {
|
||||||
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
VIRSH_COMMON_OPT_DOMAIN_FULL(0),
|
||||||
{.name = "path",
|
{.name = "path",
|
||||||
.type = VSH_OT_DATA,
|
.type = VSH_OT_DATA,
|
||||||
@ -2830,7 +2830,7 @@ static const vshCmdOptDef opts_block_resize[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
cmdBlockResize(vshControl *ctl, const vshCmd *cmd)
|
cmdBlockresize(vshControl *ctl, const vshCmd *cmd)
|
||||||
{
|
{
|
||||||
virDomainPtr dom;
|
virDomainPtr dom;
|
||||||
const char *path = NULL;
|
const char *path = NULL;
|
||||||
@ -13910,33 +13910,33 @@ const vshCmdDef domManagementCmds[] = {
|
|||||||
.flags = 0
|
.flags = 0
|
||||||
},
|
},
|
||||||
{.name = "blockcommit",
|
{.name = "blockcommit",
|
||||||
.handler = cmdBlockCommit,
|
.handler = cmdBlockcommit,
|
||||||
.opts = opts_block_commit,
|
.opts = opts_blockcommit,
|
||||||
.info = info_block_commit,
|
.info = info_blockcommit,
|
||||||
.flags = 0
|
.flags = 0
|
||||||
},
|
},
|
||||||
{.name = "blockcopy",
|
{.name = "blockcopy",
|
||||||
.handler = cmdBlockCopy,
|
.handler = cmdBlockcopy,
|
||||||
.opts = opts_block_copy,
|
.opts = opts_blockcopy,
|
||||||
.info = info_block_copy,
|
.info = info_blockcopy,
|
||||||
.flags = 0
|
.flags = 0
|
||||||
},
|
},
|
||||||
{.name = "blockjob",
|
{.name = "blockjob",
|
||||||
.handler = cmdBlockJob,
|
.handler = cmdBlockjob,
|
||||||
.opts = opts_block_job,
|
.opts = opts_blockjob,
|
||||||
.info = info_block_job,
|
.info = info_blockjob,
|
||||||
.flags = 0
|
.flags = 0
|
||||||
},
|
},
|
||||||
{.name = "blockpull",
|
{.name = "blockpull",
|
||||||
.handler = cmdBlockPull,
|
.handler = cmdBlockpull,
|
||||||
.opts = opts_block_pull,
|
.opts = opts_blockpull,
|
||||||
.info = info_block_pull,
|
.info = info_blockpull,
|
||||||
.flags = 0
|
.flags = 0
|
||||||
},
|
},
|
||||||
{.name = "blockresize",
|
{.name = "blockresize",
|
||||||
.handler = cmdBlockResize,
|
.handler = cmdBlockresize,
|
||||||
.opts = opts_block_resize,
|
.opts = opts_blockresize,
|
||||||
.info = info_block_resize,
|
.info = info_blockresize,
|
||||||
.flags = 0
|
.flags = 0
|
||||||
},
|
},
|
||||||
{.name = "change-media",
|
{.name = "change-media",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user