fix sched_setaffinity parameter : sizeof(cpu_set_t)
SCHED_IDLE and SCHED_BATCH can only be used with sched_priority 0

The function was randomly failing to drop the priority, because the
field was not initialized - it was random garbage instead of 0, leading
to EINVAL.
Fix processor count detection with HW_NCPU
Do not set thread affinity on single-processor systems
Use _SC_NPROCESSORS_CONF instead of _SC_NPROCESSORS_ONLN
Set the priority of miner threads to idle on Windows
Merge commit '8ace341' into bfgminer

Conflicts:
	AUTHORS
Allow libcurl to rewind the upload buffer
util: seek_data_cb: Check validity of offset