Skip to content

Commit c0e0c56

Browse files
committed
Improve handling on machines without JNA
1 parent 3ab7d2d commit c0e0c56

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

README

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ https://www.ohloh.net/p/Java-Thread-Affinity
44

55
[ Version History ]
66

7+
Version 1.6.1 - Improved behaviour on machines without thread affinity support esp. Macs.
8+
79
Version 1.6 - First formal release available under https://github.com/peter-lawrey/Java-Thread-Affinity/tree/master/repository
810

911
Version 1.5.5 - Added native support for Linux/amd64, thank you akerbos.

src/main/java/vanilla/java/affinity/AffinityLock.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ public void bind(boolean wholeCore) {
297297
sb.append(" to ").append(assignedThread);
298298
LOGGER.info(sb.toString());
299299
}
300-
} else {
300+
} else if (cpuId >= 0) {
301301
bound = true;
302302
assignedThread = Thread.currentThread();
303303
if (LOGGER.isLoggable(Level.INFO))

0 commit comments

Comments
 (0)