Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
DISCONTINUED:openSUSE:11.2
eject
eject-2.1.0-status.diff
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File eject-2.1.0-status.diff of Package eject
--- eject.c +++ eject.c @@ -68,6 +68,7 @@ #include <scsi/scsi.h> #include <scsi/sg.h> #include <scsi/scsi_ioctl.h> +#include <scsi/sg_io_linux.h> #include <sys/time.h> /* Used by the ToggleTray() function. If ejecting the tray takes this @@ -582,17 +583,17 @@ io_hdr.cmdp = allowRmBlk; status = ioctl(fd, SG_IO, (void *)&io_hdr); - if (status < 0) + if (status < 0 || io_hdr.host_status != DID_OK || io_hdr.driver_status != DRIVER_OK) return 0; io_hdr.cmdp = startStop1Blk; status = ioctl(fd, SG_IO, (void *)&io_hdr); - if (status < 0) + if (status < 0 || io_hdr.host_status != DID_OK || io_hdr.driver_status != DRIVER_OK) return 0; io_hdr.cmdp = startStop2Blk; status = ioctl(fd, SG_IO, (void *)&io_hdr); - if (status < 0) + if (status < 0 || io_hdr.host_status != DID_OK || io_hdr.driver_status != DRIVER_OK) return 0; return 1;
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