xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu2@citrix.com>
To: xen-devel@lists.xenproject.org
Cc: Ian Jackson <ian.jackson@eu.citrix.com>,
	Wei Liu <wei.liu2@citrix.com>,
	m.a.young@durham.ac.uk
Subject: [PATCH 1/4] pygrub: fix message in grub parser
Date: Mon, 1 Apr 2019 11:32:35 +0100	[thread overview]
Message-ID: <20190401103238.15649-2-wei.liu2@citrix.com> (raw)
In-Reply-To: <20190401103238.15649-1-wei.liu2@citrix.com>

The code suggests 0 is allowed. Zero is not a positive number.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
Backport candadiate.
---
 tools/pygrub/src/GrubConf.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/pygrub/src/GrubConf.py b/tools/pygrub/src/GrubConf.py
index f8d3799dc0..0204d410ac 100644
--- a/tools/pygrub/src/GrubConf.py
+++ b/tools/pygrub/src/GrubConf.py
@@ -236,7 +236,7 @@ class _GrubConfigFile(object):
             self._default = val
 
         if self._default < 0:
-            raise ValueError("default must be positive number")
+            raise ValueError("default must be non-negative number")
     default = property(_get_default, _set_default)
 
     def set_splash(self, val):
-- 
2.20.1


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

  reply	other threads:[~2019-04-01 10:32 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-01 10:32 [PATCH 0/4] More python fixes Wei Liu
2019-04-01 10:32 ` Wei Liu [this message]
2019-04-01 16:16   ` [PATCH 1/4] pygrub: fix message in grub parser Andrew Cooper
2019-04-01 10:32 ` [PATCH 2/4] pygrub/grub: always use integer for default entry Wei Liu
2019-04-01 16:20   ` Andrew Cooper
2019-04-01 10:32 ` [PATCH 3/4] pygrub: decode string in Python 3 Wei Liu
2019-04-01 16:21   ` Andrew Cooper
2019-04-01 10:32 ` [PATCH 4/4] tools/ocaml: make python scripts 2 and 3 compatible Wei Liu
2019-04-01 16:22   ` Andrew Cooper
2019-04-01 16:24   ` Christian Lindig
2019-04-01 20:36 ` [PATCH 0/4] More python fixes YOUNG, MICHAEL A.
2019-04-02  8:18   ` Wei Liu

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=20190401103238.15649-2-wei.liu2@citrix.com \
    --to=wei.liu2@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=m.a.young@durham.ac.uk \
    --cc=xen-devel@lists.xenproject.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).