--- a/jdk/src/share/classes/java/util/concurrent/locks/LockSupport.java Mon May 09 15:58:25 2011 +0100
+++ b/jdk/src/share/classes/java/util/concurrent/locks/LockSupport.java Mon May 09 16:36:20 2011 +0100
@@ -275,10 +275,14 @@
* snapshot -- the thread may have since unblocked or blocked on a
* different blocker object.
*
+ * @param t the thread
* @return the blocker
+ * @throws NullPointerException if argument is null
* @since 1.6
*/
public static Object getBlocker(Thread t) {
+ if (t == null)
+ throw new NullPointerException();
return unsafe.getObjectVolatile(t, parkBlockerOffset);
}