Crazy java bug?