Re: [PATCH 1/2] virterror: Fix error message for VIR_ERR_INVALID_ARG

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/26/2011 03:56 AM, Michal Privoznik wrote:
When a detail message is presented, nobody expects prefix 'invalid
argument in' but something more general, like 'invalid argument:'.
---
  src/util/virterror.c |    2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/util/virterror.c b/src/util/virterror.c
index c5babb1..f4541bd 100644
--- a/src/util/virterror.c
+++ b/src/util/virterror.c
@@ -794,7 +794,7 @@ virErrorMsg(virErrorNumber error, const char *info)
              if (info == NULL)
                  errmsg = _("invalid argument in");

Do we need to fix this one too, to just "invalid argument"? Then again, I don't know if any callers pass NULL for info (this whole virterror.c code could use some major cleanups. I have a stale patch in my local git tree where I tried to simplify things once to not have an if/else inside every case: of that function, but it would take a while to dig it out and get it into shape with the current tree).

              else
-                errmsg = _("invalid argument in %s");
+                errmsg = _("invalid argument: %s");

ACK with the counterpart line fixed too.

--
Eric Blake   eblake@xxxxxxxxxx    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]