Pushed under trivial and build breaker rules.
Michal Prívozník (2):
bhyve_parse_command.c: Don't jump onto non-existent label in
CONSUME_ARG()
bhyve_parse_command: Undefine CONSUME_ARG macro when no longer needed
src/bhyve/bhyve_parse_command.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
--
2.24.1
Show replies by date
In v5.10.0-508-gfbf3f3d86a, the 'error' label was removed from
bhyveParseBhyveCommandLine(), however the CONSUME_ARG() macro
still uses it. Fix the macro to return an error instead.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/bhyve/bhyve_parse_command.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/bhyve/bhyve_parse_command.c b/src/bhyve/bhyve_parse_command.c
index f7cedf5c65..30927ff10c 100644
--- a/src/bhyve/bhyve_parse_command.c
+++ b/src/bhyve/bhyve_parse_command.c
@@ -628,7 +628,7 @@ bhyveParseBhyvePCIArg(virDomainDefPtr def,
if ((opti + 1) == argc) { \
virReportError(VIR_ERR_INVALID_ARG, _("Missing argument for
'%s'"), \
argv[opti]); \
- goto error; \
+ return -1; \
} \
var = argv[++opti]
--
2.24.1
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/bhyve/bhyve_parse_command.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/bhyve/bhyve_parse_command.c b/src/bhyve/bhyve_parse_command.c
index 30927ff10c..dd6a626ff4 100644
--- a/src/bhyve/bhyve_parse_command.c
+++ b/src/bhyve/bhyve_parse_command.c
@@ -823,6 +823,8 @@ bhyveParseBhyveLoadCommandLine(virDomainDefPtr def,
return 0;
}
+#undef CONSUME_ARG
+
static int
bhyveParseCustomLoaderCommandLine(virDomainDefPtr def,
int argc G_GNUC_UNUSED,
--
2.24.1