Bug 1339572

Summary: Improve some logs about hotkeys
Product: Red Hat Enterprise Linux 7 Reporter: Xiaodai Wang <xiaodwan>
Component: virt-viewerAssignee: Pavel Grunt <pgrunt>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: low    
Version: 7.3CC: dblechte, juzhou, mxie, mzhan, pgrunt, rbalakri, rduda, tzheng
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: virt-viewer-2.0-8.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1351876 (view as bug list) Environment:
Last Closed: 2016-11-04 01:20:38 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1351876    

Description Xiaodai Wang 2016-05-25 11:09:36 UTC
Description of problem:
Improve some logs about hotkeys

Version-Release number of selected component (if applicable):
virt-viewer-2.0-7.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Prepare a running guest.
2. Run "virt-viewer -c qemu:///system $guest --hotkeys=toggle-fullscreen=shift+f11".
3. Run "virt-viewer -c qemu:///system $guest --hotkeys=invalid_hotkeys"


Actual results:
After step2 and step3, "(virt-viewer:1265): virt-viewer-WARNING **: disabling smartcard shortcuts" appears in terminal.
After step3, "(virt-viewer:3049): virt-viewer-WARNING **: (virt-viewer-app.c:2071):virt_viewer_app_set_hotkeys: code should not be reached" appears. 

Expected results:
1. It's better to not display non-relevant smartcard shortcuts log in terminal.
2. "code should not be reached" is not a good hint for users. It's better to give some hint about invalid hotkey settings.


Additional info:

Comment 2 Pavel Grunt 2016-05-30 09:28:11 UTC
Patches posted: https://www.redhat.com/archives/virt-tools-list/2016-May/msg00095.html

Comment 3 Pavel Grunt 2016-06-02 09:10:10 UTC
Improved upstream by commits:
7d7e8c2aae15d6d161f4651da4bb7b70bde9118d
9a3041eb0062128c84d96f37c5ead61c6f3aaa26
ffa460b8c6a1c900eb155d06245f42693bd13f3b

Comment 5 Xiaodai Wang 2016-07-01 05:51:20 UTC
I verified it with virt-viewer-2.0-9.el7.x86_64 following the steps in #comment 0.

$ virt-viewer -c qemu:///system rhel7.2 --hotkeys=invalid

(virt-viewer:18800): virt-viewer-WARNING **: missing value for key 'invalid'
$ virt-viewer -c qemu:///system rhel7.2 --hotkeys=invalid=a

(virt-viewer:18827): virt-viewer-WARNING **: Unknown hotkey command invalid

From above logs, we can see no unnecessary smartcard logs display and the correct warning log display for incorrect hotkeys setting.

So move the bug from ON_QA to VERIFIED.

Comment 7 errata-xmlrpc 2016-11-04 01:20:38 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-2229.html