Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.2:PowerPC
tuned
plugin_disk_fix_checking_removable_attribute_on...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File plugin_disk_fix_checking_removable_attribute_on_python3.patch of Package tuned
From: Ondřej Lysoněk <olysonek@redhat.com> Subject: plugin_disk: Fix checking the 'removable' attribute on python3 References: Bugfix found by git HEAD review Patch-Mainline: v2.11.0-rc.1 Git-commit: 2cc3d747986837d7e7957f5a4baede2dd691348a Git-repo: https://github.com/openSUSE/tuned.git The 'removable' attribute is a bytestring, so it will never be equal to "0" in python3. Check equality with b"0" instead. The patch was originally written by Tomáš Korbař. Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com> Signed-off-by: Thomas Renninger <trenn@suse.com> diff --git a/tuned/plugins/plugin_disk.py b/tuned/plugins/plugin_disk.py index 1de1257..65504d8 100644 --- a/tuned/plugins/plugin_disk.py +++ b/tuned/plugins/plugin_disk.py @@ -39,7 +39,7 @@ class DiskPlugin(hotplug.Plugin): @classmethod def _device_is_supported(cls, device): return device.device_type == "disk" and \ - device.attributes.get("removable", None) == "0" and \ + device.attributes.get("removable", None) == b"0" and \ (device.parent is None or \ device.parent.subsystem in ["scsi", "virtio", "xen"])
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