qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Markus Armbruster <armbru@redhat.com>
To: qemu-devel@nongnu.org
Cc: peter.maydell@linaro.org
Subject: [PULL 11/13] Tweak a few "Parameter 'NAME' expects THING" error message
Date: Thu, 10 Dec 2020 17:31:30 +0100	[thread overview]
Message-ID: <20201210163132.2919935-12-armbru@redhat.com> (raw)
In-Reply-To: <20201210163132.2919935-1-armbru@redhat.com>

Change to "expects a THING" where that's an obvious improvement

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20201113082626.2725812-11-armbru@redhat.com>
---
 block/quorum.c                   | 2 +-
 blockdev.c                       | 2 +-
 chardev/char.c                   | 2 +-
 hw/core/qdev-properties-system.c | 2 +-
 softmmu/qdev-monitor.c           | 4 ++--
 5 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/block/quorum.c b/block/quorum.c
index b10fc2089e..4b08a199b7 100644
--- a/block/quorum.c
+++ b/block/quorum.c
@@ -856,7 +856,7 @@ static int quorum_valid_threshold(int threshold, int num_children, Error **errp)
 
     if (threshold < 1) {
         error_setg(errp, QERR_INVALID_PARAMETER_VALUE,
-                   "vote-threshold", "value >= 1");
+                   "vote-threshold", "a value >= 1");
         return -ERANGE;
     }
 
diff --git a/blockdev.c b/blockdev.c
index d05a8740f4..6c7be7c522 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -2991,7 +2991,7 @@ static void blockdev_mirror_common(const char *job_id, BlockDriverState *bs,
     }
     if (granularity & (granularity - 1)) {
         error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "granularity",
-                   "power of 2");
+                   "a power of 2");
         return;
     }
 
diff --git a/chardev/char.c b/chardev/char.c
index aa4282164a..a9b8c5a9aa 100644
--- a/chardev/char.c
+++ b/chardev/char.c
@@ -521,7 +521,7 @@ static const ChardevClass *char_get_class(const char *driver, Error **errp)
 
     if (object_class_is_abstract(oc)) {
         error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "driver",
-                   "abstract device type");
+                   "an abstract device type");
         return NULL;
     }
 
diff --git a/hw/core/qdev-properties-system.c b/hw/core/qdev-properties-system.c
index 9d80a07d26..8912fb4e9c 100644
--- a/hw/core/qdev-properties-system.c
+++ b/hw/core/qdev-properties-system.c
@@ -776,7 +776,7 @@ static void set_pci_devfn(Object *obj, Visitor *v, const char *name,
         }
         if (value < -1 || value > 255) {
             error_setg(errp, QERR_INVALID_PARAMETER_VALUE,
-                       name ? name : "null", "pci_devfn");
+                       name ? name : "null", "a value between -1 and 255");
             return;
         }
         *ptr = value;
diff --git a/softmmu/qdev-monitor.c b/softmmu/qdev-monitor.c
index 301089eaea..31e5b589b7 100644
--- a/softmmu/qdev-monitor.c
+++ b/softmmu/qdev-monitor.c
@@ -237,7 +237,7 @@ static DeviceClass *qdev_get_device_class(const char **driver, Error **errp)
 
     if (object_class_is_abstract(oc)) {
         error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "driver",
-                   "non-abstract device type");
+                   "a non-abstract device type");
         return NULL;
     }
 
@@ -245,7 +245,7 @@ static DeviceClass *qdev_get_device_class(const char **driver, Error **errp)
     if (!dc->user_creatable ||
         (qdev_hotplug && !dc->hotpluggable)) {
         error_setg(errp, QERR_INVALID_PARAMETER_VALUE, "driver",
-                   "pluggable device type");
+                   "a pluggable device type");
         return NULL;
     }
 
-- 
2.26.2



  parent reply	other threads:[~2020-12-10 16:59 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-10 16:31 [PULL 00/13] Miscellaneous patches for 2020-12-10 Markus Armbruster
2020-12-10 16:31 ` [PULL 01/13] Clean up includes Markus Armbruster
2020-12-10 16:31 ` [PULL 02/13] qerror: Drop unused QERR_ macros Markus Armbruster
2020-12-10 16:31 ` [PULL 03/13] qerror: Eliminate QERR_ macros used in just one place Markus Armbruster
2020-12-10 16:31 ` [PULL 04/13] block: Improve some block-commit, block-stream error messages Markus Armbruster
2020-12-10 16:31 ` [PULL 05/13] ui: Improve some set_passwd, expire_password " Markus Armbruster
2020-12-10 16:31 ` [PULL 06/13] ui: Improve a client_migrate_info error message Markus Armbruster
2020-12-10 16:31 ` [PULL 07/13] ui: Tweak " Markus Armbruster
2020-12-10 16:31 ` [PULL 08/13] qga: Replace an unreachable error by abort() Markus Armbruster
2020-12-10 16:31 ` [PULL 09/13] qga: Tweak a guest-shutdown error message Markus Armbruster
2020-12-10 16:31 ` [PULL 10/13] qom: Improve {qom, device}-list-properties error messages Markus Armbruster
2020-12-10 16:31 ` Markus Armbruster [this message]
2020-12-10 16:31 ` [PULL 12/13] qapi: Normalize version references x.y.0 to just x.y Markus Armbruster
2020-12-10 16:31 ` [PULL 13/13] docs/devel/writing-qmp-commands.txt: Fix docs Markus Armbruster
2020-12-11  2:11   ` Zihao Chang
2020-12-10 19:30 ` [PULL 00/13] Miscellaneous patches for 2020-12-10 Peter Maydell

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=20201210163132.2919935-12-armbru@redhat.com \
    --to=armbru@redhat.com \
    --cc=peter.maydell@linaro.org \
    --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).