Bug 835937 - virsh freecell accepts non-numeric cellno
virsh freecell accepts non-numeric cellno
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: libvirt (Show other bugs)
Unspecified Linux
unspecified Severity low
: rc
: ---
Assigned To: Libvirt Maintainers
Virtualization Bugs
Depends On:
  Show dependency treegraph
Reported: 2012-06-27 11:01 EDT by Chris Evich
Modified: 2012-06-27 23:13 EDT (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-06-27 11:06:17 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Chris Evich 2012-06-27 11:01:37 EDT
Description of problem:
virsh happily accepts a non-numeric (e.g. 'xyz') cellno assuming it to be 0.  Later versions (RHEL 6+) flag this as an error.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. virsh freecell xyz
Actual results:
# virsh freecell xyz
0: 3024308 kB

Expected results:
# virsh freecell xyz
error: cell number has to be a number

Additional info:
Discovered this with a new 'freecell' test on libvirt autotest, However problem is easily reproducable by hand.  It's a very minor issue, but filling it anyway in case it's an easy fix.
Comment 1 Eric Blake 2012-06-27 11:06:17 EDT
It may be an easy fix, but backporting introduces risk, and since the problem only occurs on invalid input and only impacts virsh, you are better off passing valid input rather than asking us to backport a fix.  At this point, we want to backport as little as possible into RHEL 5, focusing purely on bugs that have a larger impact to libvirtd itself.  I'm marking this as WONTFIX.
Comment 2 Chris Evich 2012-06-27 11:18:49 EDT
Understood, and fair enough.  Thanks for taking a look.

Note You need to log in before you can comment on or make changes to this bug.