Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP4:GA
nvme-cli.20721
0005-nvme-ioctl-return-1-on-failure-from-nvme_g...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0005-nvme-ioctl-return-1-on-failure-from-nvme_get_nsid.patch of Package nvme-cli.20721
From: Hannes Reinecke <hare@suse.de> Date: Tue, 22 Jun 2021 13:40:23 +0200 Subject: nvme-ioctl: return -1 on failure from nvme_get_nsid() References: bsc#1186719 Git-commit: 22c19f6a5b58ad9ce99d2c2a95239eab911d908e If the call to 'fstat' fails we should be returning '-1' (as the errno is already set by fstat()) to be compliant with the return values from 'ioctl()'. Signed-off-by: Hannes Reinecke <hare@suse.de> --- nvme-ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nvme-ioctl.c b/nvme-ioctl.c index cc12ae60d06d..64152b1cfd0c 100644 --- a/nvme-ioctl.c +++ b/nvme-ioctl.c @@ -68,7 +68,7 @@ int nvme_get_nsid(int fd) int err = fstat(fd, &nvme_stat); if (err < 0) - return -errno; + return err; return ioctl(fd, NVME_IOCTL_ID); } -- 2.32.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