From: Cole Robinson <crobinso@redhat.com>
To: qemu-devel@nongnu.org
Cc: Luiz Capitulino <lcapitulino@redhat.com>,
Markus Armbruster <armbru@redhat.com>,
Cole Robinson <crobinso@redhat.com>
Subject: [Qemu-devel] [PATCH v2 8/9] qerror.h: Replace QERR_NOT_SUPPORTED with QERR_UNSUPPORTED
Date: Fri, 21 Mar 2014 19:42:27 -0400 [thread overview]
Message-ID: <08bc0deb8fb1d1e96df3d14e377cdc948d9c0660.1395445063.git.crobinso@redhat.com> (raw)
In-Reply-To: <cover.1395445063.git.crobinso@redhat.com>
In-Reply-To: <cover.1395445063.git.crobinso@redhat.com>
The former is only used twice, the latter is used over 30 times, and
has a nicer error message.
Cc: Luiz Capitulino <lcapitulino@redhat.com>
Cc: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
---
blockjob.c | 2 +-
include/qapi/qmp/qerror.h | 3 ---
stubs/arch-query-cpu-def.c | 2 +-
3 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/blockjob.c b/blockjob.c
index b3ce14c..cd4784f 100644
--- a/blockjob.c
+++ b/blockjob.c
@@ -88,7 +88,7 @@ void block_job_set_speed(BlockJob *job, int64_t speed, Error **errp)
Error *local_err = NULL;
if (!job->driver->set_speed) {
- error_set(errp, QERR_NOT_SUPPORTED);
+ error_set(errp, QERR_UNSUPPORTED);
return;
}
job->driver->set_speed(job, speed, &local_err);
diff --git a/include/qapi/qmp/qerror.h b/include/qapi/qmp/qerror.h
index 01d1d06..f5335e6 100644
--- a/include/qapi/qmp/qerror.h
+++ b/include/qapi/qmp/qerror.h
@@ -122,9 +122,6 @@ void qerror_report_err(Error *err);
#define QERR_MISSING_PARAMETER \
ERROR_CLASS_GENERIC_ERROR, "Parameter '%s' is missing"
-#define QERR_NOT_SUPPORTED \
- ERROR_CLASS_GENERIC_ERROR, "Not supported"
-
#define QERR_PERMISSION_DENIED \
ERROR_CLASS_GENERIC_ERROR, "Insufficient permission to perform this operation"
diff --git a/stubs/arch-query-cpu-def.c b/stubs/arch-query-cpu-def.c
index fa67895..22e0b43 100644
--- a/stubs/arch-query-cpu-def.c
+++ b/stubs/arch-query-cpu-def.c
@@ -4,6 +4,6 @@
CpuDefinitionInfoList *arch_query_cpu_definitions(Error **errp)
{
- error_set(errp, QERR_NOT_SUPPORTED);
+ error_set(errp, QERR_UNSUPPORTED);
return NULL;
}
--
1.8.5.3
next prev parent reply other threads:[~2014-03-21 23:42 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-21 23:42 [Qemu-devel] [PATCH v2 0/9] error: Misc cleanups and improvements Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 1/9] slirp: Remove default_mon usage Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 2/9] vnc: " Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 3/9] error: Privatize error_print_loc Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 4/9] monitor: Remove unused monitor_print_filename Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 5/9] error: Print error_report() to stderr if using qmp Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 6/9] qerror.h: Remove unused error classes Cole Robinson
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 7/9] qerror.h: Remove QERR defines that are only used once Cole Robinson
2014-03-21 23:42 ` Cole Robinson [this message]
2014-03-21 23:42 ` [Qemu-devel] [PATCH v2 9/9] error: Remove some unused headers Cole Robinson
2014-03-22 9:06 ` [Qemu-devel] [PATCH v2 0/9] error: Misc cleanups and improvements Paolo Bonzini
2014-03-27 20:57 ` Luiz Capitulino
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=08bc0deb8fb1d1e96df3d14e377cdc948d9c0660.1395445063.git.crobinso@redhat.com \
--to=crobinso@redhat.com \
--cc=armbru@redhat.com \
--cc=lcapitulino@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).