Disallow specifying number of threads as zero.