mirror of https://github.com/GOSTSec/ccminer
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
415 B
25 lines
415 B
11 years ago
|
#ifndef __COMPAT_H__
|
||
|
#define __COMPAT_H__
|
||
|
|
||
|
#ifdef WIN32
|
||
|
|
||
|
#include <windows.h>
|
||
|
|
||
|
static __inline void sleep(int secs)
|
||
|
{
|
||
|
Sleep(secs * 1000);
|
||
|
}
|
||
|
|
||
|
enum {
|
||
|
PRIO_PROCESS = 0,
|
||
|
};
|
||
|
|
||
|
static __inline int setpriority(int which, int who, int prio)
|
||
|
{
|
||
|
return -!SetThreadPriority(GetCurrentThread(), THREAD_PRIORITY_IDLE /*THREAD_PRIORITY_TIME_CRITICAL*/);
|
||
|
}
|
||
|
|
||
|
#endif /* WIN32 */
|
||
|
|
||
|
#endif /* __COMPAT_H__ */
|