cpuminer/compat.h
pooler e0dc6649e1 Version 2.0
- Test the whole hash instead of just looking at the high 32 bits
- Set idle priority on Windows
- Fix parameters -u and -p, and add short options -o and -O
- Fix example JSON configuration file
2012-01-17 00:38:06 +01:00

24 lines
352 B
C

#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 -!SetPriorityClass(GetCurrentProcess(), IDLE_PRIORITY_CLASS);
}
#endif /* WIN32 */
#endif /* __COMPAT_H__ */