mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-09 06:18:06 +00:00
cross-compile: comment out sleep().
Reported as unneded: https://github.com/veox/sgminer/issues/37 When is this true? Which IDEs, Windows/MinGW versions?
This commit is contained in:
parent
08abb9e417
commit
06240b91a6
19
compat.h
19
compat.h
@ -47,15 +47,16 @@ static inline int nanosleep(const struct timespec *req, struct timespec *rem)
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline int sleep(unsigned int secs)
|
||||
{
|
||||
struct timespec req, rem;
|
||||
req.tv_sec = secs;
|
||||
req.tv_nsec = 0;
|
||||
if (!nanosleep(&req, &rem))
|
||||
return 0;
|
||||
return rem.tv_sec + (rem.tv_nsec ? 1 : 0);
|
||||
}
|
||||
/* Reported unneded in https://github.com/veox/sgminer/issues/37 */
|
||||
/* static inline int sleep(unsigned int secs) */
|
||||
/* { */
|
||||
/* struct timespec req, rem; */
|
||||
/* req.tv_sec = secs; */
|
||||
/* req.tv_nsec = 0; */
|
||||
/* if (!nanosleep(&req, &rem)) */
|
||||
/* return 0; */
|
||||
/* return rem.tv_sec + (rem.tv_nsec ? 1 : 0); */
|
||||
/* } */
|
||||
|
||||
enum {
|
||||
PRIO_PROCESS = 0,
|
||||
|
Loading…
Reference in New Issue
Block a user