Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.5:Update
virt-manager.24918
virtman-check-for-valid-display.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File virtman-check-for-valid-display.patch of Package virt-manager.24918
References: bnc#907958 Sanity check for those who forget '-X' on ssh and try to start virt-manager Index: virt-manager-3.3.0/virtManager/virtmanager.py =================================================================== --- virt-manager-3.3.0.orig/virtManager/virtmanager.py +++ virt-manager-3.3.0/virtManager/virtmanager.py @@ -66,8 +66,11 @@ def _import_gtk(leftovers): print("gtk3 3.22.0 or later is required.") sys.exit(1) - # This will error if Gtk wasn't correctly initialized - Gtk.init() + if 'DISPLAY' in os.environ and os.environ['DISPLAY']: + # This will error if Gtk wasn't correctly initialized + Gtk.Window() + else: + raise Exception("Error starting virt-manager: No graphical display found") globals()["Gtk"] = Gtk # This ensures we can init gsettings correctly
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor