Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
Please login to access the resource
openSUSE:Leap:42.2:Update
util-linux.6436
util-linux-lscpu-wsl-regression.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File util-linux-lscpu-wsl-regression.patch of Package util-linux.6436
From 4dfc54b6b17386d68a621d6c7f4e341e8736340f Mon Sep 17 00:00:00 2001 From: Karel Zak <kzak@redhat.com> Date: Tue, 31 Jan 2017 13:44:43 +0100 Subject: [PATCH] lscpu: make osrelease file optional Signed-off-by: Karel Zak <kzak@redhat.com> --- sys-utils/lscpu.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c index 0ba815428..318e93b43 100644 --- a/sys-utils/lscpu.c +++ b/sys-utils/lscpu.c @@ -918,7 +918,8 @@ read_hypervisor(struct lscpu_desc *desc, struct lscpu_modifier *mod) /* We have to detect WSL first. is_vmware_platform() crashes on Windows 10. */ - if ((fd = path_fopen("r", 1, _PATH_PROC_OSRELEASE))) { + if (path_exist(_PATH_PROC_OSRELEASE) + && (fd = path_fopen("r", 1, _PATH_PROC_OSRELEASE))) { char buf[256]; if (fgets(buf, sizeof(buf), fd) != NULL) { -- 2.11.0
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