add a fix for java hanging on Mountain Lion